CASE.EDU:    HOME | DIRECTORIES | SEARCH
Case Western Reserve University

KELVIN SMITH LIBRARY

 
 

So, here's a fun little test

Just playing around here a little bit. Let's see what happens when you paste in a block of PHP code!

$r = 0;
$g = 0;
$b = 0;
$col = 0;
$clim = 6;
print "

\n";
print "\n\t\n";
for ($b = 0; $b <= 5; $b++) {
$cb = 5 - $b;
for ($g = 0; $g <= 5; $g++) {
$cg = 5 - $g;
for ($r = 0; $r <= 5; $r++) {
$cr = 5 - $r;
$bgcolor = "#".dechex(3*$r).dechex(3*$g).dechex(3*$b);
$color = "#".dechex(3*$cr).dechex(3*$cg).dechex(3*$cb);
if ($col == 0) {
print "\t\n";
}
print "\t\t\n";
$col++;
if ($col == $clim) {
print "\t\n\n";
$col = 0;
}
}
}
}
print "\n\t\n";
print "
Web Safe HTML Color Values
$bgcolor
Mouse over cell to display forground and background color codes
\n";
?>

Trackbacks

Trackback URL for this entry is: http://blog.case.edu/dkh2/mt-tb.cgi/150

Comments

Post a comment





If you have entered an email address in the box, clicking this checkbox will subscribe your email address to this entry so that you are notified if any updates or additional comments occur on the entry.











Email This Entry:

Send this entry to:


Your email address:


Message (optional):