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:

DFB53E
665366
DBA0AE
6CA2A7
9F8D9D
180064
E984CA
9791C6
4ADA53
59B53C
06AE91
2FC636
DDFB10
F1B732
54BCEE
C1CBCF
DF84C8
5F16B8
D7DB0C
5FED5A
99192C
FD9995
912186
C5DA93
2A6724
59F568
859FEF
F51EA8
D76253
5A4D9C
6B25B4
19E536
0F7D8D
2B86E0
D4B482
AD8CE7
53C61D
6DDD92
404B5E
9A996F
E25CE2
AA13C2
DE718E
C22137
7DB0DF
9F8B59
CE7BDA
D54DBD
07F01F
FC9BC9
4B6C0A
6EE522
C38277
07227C
6BE84C
0F8946
D2D285
987BDD
EF4DFA
C6606C
E124C6
1CE038