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:

661931
B9CA7A
3A6F49
F64FE2
14F0C1
BA55A8
D90098
02ED19
071C9F
A18458
C40088
A5C8DA
A507FE
6DFD86
52B717
A2B396
37ADE7
102938
4FBB22
9784E5
E9B83F
65C5F6
64B309
6EF9C4
212A24
074189
D41C2C
468C3F
6EAF6D
847726
AB97C4
88F3E6
AEE732
AC5B0F
FE1256
648320
73D61C
907A63
2C136E
57FF2A
308D3A
A0E190
A0F43C
53EBD1
5F5CFD
C61968
5F76F2
D2C6C0
55B422
20AA79
FE281D
4083CC
D468C2
2BAD48
890CC8
508D67
6B1FEE
CE27B0
FFFBD4
1E1848
36A6D4
F1E633
A85225
CBAA05
9DCB08
877A6C
EF6706
E6C89C
9A1DCB
9AEA78
C07CB2
67A5CF
129708
034BBB
236E6C
1997C8
6E4515
DD6499