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:

14C44D
F7F24E
DD0E49
4C178A
7509A1
4AAA0F
608EDF
37EEC3
17EA90
2E7EE2
BDD157
1B5025
8F7399
6A4E10
509DCF
2C6106
C8A511
FCF861
89A16A
541353
2CAE43
B76D7C
0F8D22
78BD7E
5BD3B1
F57957
A2681F
7DCFFF
5CB266
C882AE
151140
B91B4F
F97E36
9B6416
21DF96
A46C4C
9CD916
442D32
0C72C5
1AF274
C16734
7DBF83
4782C4
3D76BF
E60367
4927E6
713A8F
CE1D80
981D24
709797
86A7F6
FA5F04
D79C50
C7A319
877F48
593C0D
E6AF77
B62FEB
73F47C
50CB35
E50C0F
DB33BB
46E102
63CBEE
CDD7EB