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:

C0FB8A
D02DE0
725B54
A2002E
FDD750
CE9363
31B151
1926DD
093568
F66E24
E5F44F
2890D8
10DDB1
55525B
6B0CD5
57560F
F686DB
A52DC3
2F25A7
761355
271BA0
D841C1
244719
4B70CD
80A75A
ABFFF2
220D71
8A0B21
561B88
A4A071
BE2E07
08855F
B14B73
522EC5
6C522D
69974A
901E9C
F63776
23D754
03D423
8DFD65
F6E63A
BD528E
7E4865
65DA19
E0D971
DB2921
E8ED8C
1A941A
50C5E2
BEE62F
F1FA02
BDE367
2305CC
87C734
B7864E
3DEAF1
20A948
2AB71F
845FD7
F12477
5F965B
D17DC2
1B2936
07DBFC
2F6F73
D6A96E
8293C2
F2DF55
7FAB33
7F5D04
73E813
E665C7
DD1AB8
34962B
E0A354
11506A
554D7B
6A9C50
0D3B0E
0F3B0E
3AFE0D
6CDC4B
278ACB
38FE94
65BC0F
4B8D50
B4C570
097919
719331
49E07C
9B1C5C
EA9F49
B4C47F