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:

F48182
192C8F
4EB595
AE62A1
E20DDF
D80375
55A0A2
8B39C3
75614E
61D9EC
DA4D25
903795
0C6181
313A18
02A39F
6A5FAE
EEEDFD
3E8619
0B9AF7
5ABB6F
CA33F3
592898
4AE70F
B5E8F5
14026A
951A6B
390B6D
5C9B5C
9D146E
AB2BA3
C79C20
D05062
B4D2A8
009951
2B9174
F6DBA1
0F9DC5
DC546C
88F704
5969C7
2BB79E
1658A5
245E07
320479
5F4C75
355F9E
EC5A7B
131945
0D2B53
D48920
18D526
A41F6E
42FB07
11D544
E38DED
DF1C08
207943
C06477
C2342D
CA0530
6E21EB
46117A
6D5018
F1DB19
8FF5DE
9ABCEC
43C454
4CA2B2
95C08F
64508C
0D0B1A
A1FE0A
7482F4
4A2C85
19D679
564E26
E84508
1770F4
72969E
1D67BE
C0B98F