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:

118D44
F67FCC
9D3E28
1F9B65
E16239
92A1D2
56D1B1
824C4A
35C4A6
5F0A21
7C735E
A0C845
70A7A1
11530C
C10A65
6F0D39
5272F5
FD6895
CFCDCF
BC21A9
4077F5
BA065E
023337
B6C724
C293A9
108BEB
1EA814
FF438A
443309
10F42D
09A42A
583A5C
748D29
78B13C
A6FA6E
B9983B
FC6DFD
613F97
FB0212
A015ED
7CA914
B55BE4
5CB783
8948B7
A69FEA
AB0CDA
CF2A92
D78F7F
1C3629
33D3A1
5424C8
C365F5
308888
8AB2E9
A08484
4ED372
B979A1
A29D83
E5BF9D
193689
575598
0E2235
C62394
BC4EED
D26DDA
E1E2E4
64A731
0EBAB1
F3844A
A0E91C
5BE5A0
4318DF
39F6DE
4B276A