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:

2DD5CA
B31623
EFEF9B
1072C9
EAE84E
25262E
0F1619
47E92F
89FDF6
31E96F
A0381A
F386AE
D0E9AF
59861B
B56D6F
ED581A
7D29B4
046070
3AA9FC
E8A9F4
442A7E
98EAEB
1639D1
08C290
E4B719
CE187C
527D16
8A8D6F
8E3FF2
33D078
A09EB2
3500BD
08DF26
69638D
38A039
3DF000
66597F
AA26B0
6572E2
3465CA
8E949E
C9122D
E6DBB6
9E1D8B
EAC6A5
F3DC6A
0A39B4
4283CF
6610CE
274C38
ABBB8F
293754
F1E16D
C28F4A
442EBA
02B7E3
A0F934
8B3D92
D9D707
910D6B
576611
61FE98
AEAC45
FD8833
94BE0B
52B65F
DD59A7
BDA002
60469C
131F03
D83B4D
0FBF01
CC2596
F936B2
AF733B
2E4AA5
2A7446
81B98D
C2C449