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:

369420
CAB53D
F54A25
F07325
0ED1A4
E70F9F
9F6C58
25A561
B6651F
EC57FF
2AC150
D9A4E9
E7B3A7
5DA4BD
7B04B9
5FD124
2CEDD1
89F563
C85348
EB7BCB
8941B5
BB2EC8
94114B
962A25
87F366
CE03B0
F484FB
D49A6E
359C07
0FDA3E
F603C4
BB2425
823FF6
3C8EC9
03474E
6A6C6D
D76232
6A31FC
F05F68
F56D48
1D48F2
6884EC
244EC7
9B13F2
D1A6F0
A180C4
23A276
F4D867
75D822
60FC96
698806
2D8D84
FD047E
510B2B
131917
E7A8F2
BBAE0A
59041B
0F19B4
B2E81B
30A0B7
D29449
C8F794
2D1A25
36B740
B55F5C
2514FD
C14D80
F86ECB
7DC012
B29A95
1AFB28
413444
6C62BD
C9566B
A5A19A
B07189
5B9904
5E96B5
45937E
3834C3
2FD7B3
7D87C0
486C44