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:

31F1F0
D53DCE
6BEB17
C37600
D07D03
05BE50
69F4E5
5770D4
675907
69516C
7C1364
246396
82D49E
C2233C
00C020
9397D2
13D855
502AC7
936BD9
53C9C7
A11A30
77D2E0
87A536
E3042F
3EA3D6
63EED1
AE3024
0734FF
627066
28D952
289EE9
444581
2B5312
1B9C34
0C7D8C
2980B9
20360A
1AD214
F5FDCE
FB37B4
42DFC6
7070F3
C2124C
0DEF0B
3308E9
AD8004
B608C6
5EE3CB
BC865C
A58CC5
6E224F
C8CCD3
2E4C26
E99680
3BE7A0
BAC89F
DAA93E
D5ED73
571BB2
D33178
43B5D7
132094
FBD90F
4DDDD9