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:

17B058
4F4510
EB27AD
5C7931
19FCB3
7922AF
ECA4DE
20357E
187626
F5F219
762460
F21F39
F6A07A
5BFE6A
4180CB
F5E1B3
1DD37B
D1FB16
C4C271
5566E6
3CE2ED
BF6FAE
65E3B6
FB320B
1CCC92
BBC5E3
7CEAB8
937899
815370
2D90DC
B9CB19
8688D6
B0F104
806875
9E9735
56911C
820F2A
C11574
4B610F
38AAF8
7CBBB9
4A04FA
A67EB6
B8D4C9
51CD02
0EA2C4
7AF746
3204BA
5BB4B4
B91606
0D6177
2F4995
08AD99
EA2E32
F9FCCF
B8857B
DB5159
E20ADA
DA7AC5
FC96FA
FE0573
0EB258
421A77
9FE306
2A9394
A624C7
627908
E89CA2
57C67A
5808B6
0665AC
FD3DE7
B13B17
D128A8
8EE075
31817E
517BDA
72423D
3F3FAC
55BC7C
496035
779671
663292
5768C5
9F0605
06165B
5BB672
20A0D1
282FD8
9D61ED
79E823
62AA8E
97DCA3
0F0E04
569B0E
56DC64
C448D0
7DDF50
9EFA22