Hallo
Ich habe wieder ma' ein kleines Problemchen
Irgendwie bricht die for Schleife aber immer ab, warum ???
Liebe Grüße,
PCFreund
Ich habe wieder ma' ein kleines Problemchen
Code:
<?php Header("Content-Type: image/png"); $width = 100; $height = 100; $img = ImageCreate($width, $height); ImageFill($img, 0, 0, ImageColorAllocate($img, 0, 0, 0)); $widthcount = 0; for(;;) { $heightcount = 0; for(;;) { ImageFilledRectangle($img, $widthcount, $heightcount, $widthcount+1, $heightcount+1, ImageColorAllocate($img, rand(0, 255), rand(0, 255), rand(0, 255))); $heightcount = $heightcount+1; if($heightcount >= $height) { break; } } $widthcount = $widthcount+1; if($widthcount >= $width) { break; } } ImagePNG($img); ?>
Liebe Grüße,
PCFreund
Kommentar