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:

6CE10F
1BC069
227FDE
9D10D2
F7A1F2
1B6B39
E062DE
D493DB
61811E
841DF0
FA7222
45ED90
453E6F
19E728
544A3F
0936DB
5207D9
A8825B
80A028
63173A
29BD39
7AF9CD
99B8CD
09EA6A
14AFDB
00A25C
D8A208
C461FF
5578C1
8C8890
78AF7A
8BEB4F
93AEFC
E92C00
42BB17
43A0A2
72AFB0
A64E6B
5A636B
0D47DA
A6A2A0
D1912C
BFDCB8
F85E78
9D2E96
0987E8
1035CC
4FDA49
08CDA0
965A03
13ECEE
7647D2
C412B4
B98AB8
D31D2D
8A3866
431D58
797A21
731B37
5C932D
734107
43B7A2
CF2780
F9A7B0
5C0162
29D164
F8CF8C
C137A1
436CFC
4155FA
640BEB
313556
46F208
9E6B5E
47DFB4
08815B
D6677F
5B5D4E
B97842
D78D6C
F29A61
AACEFD
80959B
F89B71
A93D54
CA6EDF
A41FBA
29F9C7
2BD481