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:

14342E
9846A2
A8F99F
18D81C
8C8D7D
27D4BE
4F2F0F
A4D8FB
EE9593
439F39
791967
85F952
98AA7A
95C217
86BD6B
B1579E
3A9510
50AEC7
CE95F4
F89FAF
17B5F3
941EB5
9D50D9
EC5D6E
21BF63
BC2E14
2F3B9D
061B5D
E65917
47FFD0
B218C7
35B44F
C40FBB
D0D0D6
B885A8
3B90A3
FE8310
C37D8B
992F6E
5E567D
62910C
B3AA2F
B08CF1
3E9814
EE9935
9BD124
24E240
DD4E9D
ED5308
D9AA2D
572CA5
89D9C7
38A678
0A2A67
569A67
D92FDD
096682
D975A0
2B26E1
695375
9B72D1
E57796
80557D
0CB56C
D92FE6
D3564A
5B1ED9
C58241
E60852
4F810D
5261F1