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:

FEB5DA
82C58B
744509
FD126F
6E51E0
17E07C
353765
E37465
B6BCA6
D0BC00
B30F5A
92AC16
C2FE4B
6024AC
AD1AAF
752C8F
71964E
E2F755
8D564F
3D67BD
7C9528
ACD437
E2FACE
6F371B
773F7F
946FD0
E6FB0C
625890
B7B7FE
DEBB3B
46D368
336ED2
1C717D
4918EC
303EA9
B357BE
D68BFE
4EADF3
EFCF02
B9C126
81360D
530093
4F3A03
EBDFD6
B10066
F21419
4EDD6F
1AC8A0
24A2B2
EED64B
63E0BE
E316A3
2DB1D0
B9D24B
00222D
284175
CFC54E
1C32D6
C08026
5BA457
11E647
092CC1
C5D0C2
C9DDE4
E4D314
E2DA15
9C7EAF
9C0A67
66C807
071AB5
07B36C
639073
AE8C23
FE3510
99E987
E33139
2275A2
C7BD64