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:

C85447
059B2A
471A13
3DC2B7
5FD657
EF17FE
BCE3FE
F4BA0E
6EE561
D3E8AD
087916
B27859
FCC1F9
191F1B
814887
647BA1
34820A
71CD4F
216C44
806A50
377432
E19EEB
CEEBA9
97DB04
B412FE
451E63
3BE2C9
4F54E5
29B08A
066D2C
65F944
20C419
4147D6
8D06FF
175B8C
1F7D09
3FDD90
DBCEFD
7C0654
4A20B1
E8E18D
EDE8E1
D6D93E
17F40C
963A3C
5B64A1
08EEA3
72E94E
CD505B
073040
04C3AC
B1FF18
9A2B8C
0E01BC
A08F71
BCAA90
676760
201DBE
2AA0EE