Home
Source Tarball | Source Zip

This little page does a few nifty things via PHP:

  • Generates a random quantity, between 1 and 100, of hex color codes.
  • Calculates the best color, either black or white, to use for the text to show up when displayed on top of the color.
  • Populates a little div block with the color as background and the label with the white or black text.
  • Calculates two darker shades of the color to be applied to the various parts of the object.
  • Randomly picks one of two different object templates. One faces left, the other, right.
  • Paints three of the parts of the object shown below
  • Combines each of the four parts as layers into a single little object image to be displayed next to its color block.
  • This is the right-facing template:

B5CBA7
644304
C0E1EF
0617EF
276E31
6B4D71
185B0D
7F539E
F233C5
0ED3BA
DEC604
5734DA
A4EC24
CA60E9
4EB795
FB82E7
0E4DE7
038B4D
F6974E
E1EE1C
3F02AE
78499A
D1FC44
DAD13A
668E9A
D18A4E
E6A80C
0DF226
AA00DD
8C268C
9EC31E
A6D9F8
7D6661
3396FF
FF1F74
FBC7CD
782AFD
B91B9A
74E038
2B1E09
B1AB63
D2B19D
7E12E0
799D04
BE6428
FCB9BD
37852B
8D3E18
F82BCD
950FA8
803398
9FF8CA
9469DE
E41F2E
842A0B
0A759C
F95E10
522F5F
9036CD
2F8959
890642
99DE98
D70373
5F6CEF
0F65B5
862932
8467D9
DFE742
9AA01B
D9F75F
AB3898
7248C6
92D2C1