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:

27CE95
178926
B25ECA
5DA167
0F7C19
96BD13
E08E93
B784CE
0B4619
720203
867118
6A40A2
35FF1A
61B975
27CA8E
72725C
7EF9C4
0AECD6
7A73C7
1D4BFE
E1FDE3
BC3369
3420E9
A9131F
AF8E55
0596C7
A1494B
26E51D
C1DD4D
FA3912
7B19A2
35DCE1
58A312
0C502B
F9AD65
B94545
BDD89C
611117
E13695
60EF79
DAF735
5F7F55
B1569D
9E039E
0A7BD0
E84F59
E532D1
214884
CF9283
4FA60B
AFACE8
BF76F8
53A077
53B703
8A5478
919A28
B0418B
3792B0
0630B6
D88629
6F9A84
6F7554
295919
F7177C
E13D49
42CC12
ECED89
9139CF
B1DCD8
894FCA
61C254
C704DC
D2098B
7D6993
F21376
46CABA
1A6008
652093
77EFF7
409F04
0694A2
3167CA
412867
FEB5A8
0D39B2
0EB9FD
70AC1C
5D7292
0E62FD
057F76
1674C0
A56C8A
FF035D
8312F8