Hi there,
Could you please tell me what is wrong with this php code? It is copied from an O'reilly PHP book, but when i place it in my browser, i get an error message on the 7th or 8th lines.
PHP Code:
<?
header("content-type: image/png");
$image = imagecreate(400,300);
$gold = imagecolorallocate($image, 255, 240, 00);
$white = imagecolorallocate($image, 255, 255, 255);
$color = $white;
for ($i = 400, $j = 300; $i > 0; $i -= 4, $j -= 3) {
if ($color = = $white) {
$color = $gold;
} else {
$color = $white;
}
imagefilledrectangle($image, 400 - $i, 300 - $j, $i, $j, $color);
}
imagepng($image);
imagedestroy($image);
?>
Thanks much for your help,