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:

217970
011AFA
1ACD4F
A40A1B
6DBE23
9CE6BD
CD4423
DF5D30
950CFA
89829D
B8B474
3AE592
82A9B2
5ADE80
467C0F
8C012C
E5B0B5
DC6CA1
3DB027
1F7E50
E284EE
37A199
E1BA3E
1B9ED6
A70EDC
E9085B
F3A0AD
43C2F6
0D8966
5F33C1
6524C9
6CED0A
ED265E
E1C995
9E1D38
C74CFA
8F99D4
FAEF82
6B3999
7A4669
1F8FB5
606D1C
6E0ACF
09201D
7BA6FC
6E7710
2C0A59
A40438
480E7F
54CAA3
42F0EA
51341D
E49FDD
EA53A5
4DEB4F
4BFBD1
15C315
DCB2C4
4B89E5
8F02D3
A1AB42
CDE8BD
CB251D
BD758D
096B47
53FE9B
E1613B
5EE11B
6CB459
CABD72
F67B92
DE27EC
95784E
9D717D
179EBA
F9944D
3BE513
CA20EA
B41F03
CEC25B
603F05
95C5F6
F09A80