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:

90DA07
ED79A6
771DDE
CD402A
EAE101
37FC57
5472C2
1F08E2
8E0182
E46FE7
C998D8
2A2587
13FDEC
DB5D76
49550E
A2F1EB
404852
649A4B
3B01F7
84B6A1
0912D2
E4DDED
2E090F
746708
4E622C
1E05C8
96827F
F4C8B6
CF5DC0
0E7F85
20AE16
FE7EA7
554271
23BF6C
315E68
212D22
12AE3E
E08D12
48EB34
03871D
59AF43
00BA67
515943
61D464
1F67C0
B15C9D
48AF68
B6D900
879022
43C799
72C769
3CC3E9
084CC2
3ABED4
297D3B
56E95C
F25534
C340C7
0F8F70
16D3D8
2C7AB8
ED1D28
7E60F6
1B8B83
A673D8
4B4E01
0153A3
B6B755
9A9B23
88CE0B
0184F4
A5CD57
4A118C
106182
E1909C
BD58CC
18E426
25B621
2E5381
F1D8D7
1BAA02
C8EE18
527BA7
85EC1A
05B13B
FD0E67
9586DD
EECB96
CD7F7A
DB22F4
00ECB5
B09865