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:

AE0F65
00DE6A
1FEE88
FCEBFE
AB35D3
3220FF
77D900
1988DF
E8469D
F3ABAC
EDEBBB
9C6EE1
C9F116
DFEDF9
C8B7A7
8873BF
15F5B4
A8527B
F3D1B1
6D1363
EBAC45
D1A3C6
53ADA8
759C83
E95D21
A7C3AB
78A72C
50120E
AC5BD0
8BD980
EEBAA4
BD97F5
7E85BD
FCE62E
7CA2D6
A523E5
9C76C6
61AB77
1DFDBA
2D3E0E
8AC2A3
664BCD
ADCF06
54C307
966EE1
392100
46DB33
EE2E17
B9DCF3
37EE61
BECD11
BE966B
72ABA4
8521F2
E7DDDD
6C3725
3B36B8
D02314
977DD0
CBFC4E
55FF30
F9E3B5
DA3E6C
E4671A
03070F
1D6F97
0DFF90
FA3DB6
1954D0
4A040B
43FA08
FCD929
ED4421
574898
CE2E86
BF38AB
441791
BA2136
B4CE59
EC2AFC
A4DDF0
09784C
232404
784EA0
38A082
86A7CA
353131
99427C
D2D19F
18D33C