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:

4900FC
731D70
79CA75
DCB113
65FE99
DC069D
EC6CF2
6FA4BC
378374
B02B60
7D8AFD
ACDFD6
0F3F18
865110
E4F320
C8A427
997A19
29F1E6
4185CA
BA63BB
11C0D9
FED6B3
93A5B3
324F6E
A0791F
8CAEF4
48B408
269F9D
33562B
16CFE8
1E68D9
8F0DC2
2F6A61
F551D9
4BCE0F
4F9DEE
7E6F01
8C04B3
C283F6
FFF612
72A5C4
4413A2
20FA85
CE7E79
CF5FE0
B425AF
BC3BC2
7710DF
B7FCAB
D1DF26
CD400D
86EA84
36FF54
A4B742
5243C7
2B8508
7D681F
49A737
011E24
DD12F8
32211A
78D475
E30F67
1F670D
073986
B9FF61
D6F47D
6FF4A0
CB1A5C
A7BB7D
2D9ED7
737CBB
6588D7
4AA31C
7BCF4F
FF62A3
78FC74
A6E9EC
636957
B108F2
E42807
CF57DB
9355D8