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:

22DEC2
97A611
13A6A0
B281A9
585171
480FA6
5E3066
F0AAD5
7C3F9B
E0B9B5
407BCC
F652F5
D79223
C60C5E
237E99
F789DD
1E14D9
F0397E
3A0456
005E6D
EEE77D
A53243
A14280
3FD8D6
A77AE3
40E2BA
26DF52
748E6C
7BDCC2
FC557E
37DEA2
11B4D4
FE596F
AA27C8
42C3B0
DE0EA0
969893
F6BFFF
474B45
492949
67F8CB
E77B4B
8F94B2
8ACB80
28F47D
32085D
7A3865
B7815B
DD193C
AC9B85
96AA64
2A6C4D
D02B58
DEEDA8
161DBD
BE8C05
563D45
A491BB
0855B5
06923E
560A30
E2FC48
0979F1
62C370
09A682
83E3DF
9C4DD4
27B5AE
393766