You don't put type declarations in PHP functions.  ie. get rid of all the 
"int" things there on line two.

-Rasmus

On Mon, 29 Oct 2001, Richard Marks wrote:

> mebbe you can figure out why this dont work! :)
> 
> Parse error: parse error, expecting `')'' in /(PATH NOT SHOWN TO PUBLIC,SORRY) 
>/www.gzmsoftware.f2s.com/php/fractal.php on line 2
> 
> --------------------------------------------------------------------------------
> 
> <?
> function box( int $im,int $x,int $y,int $x2,int $y2,int $color )
> {
>  imageline( $im,$x,$y,$x2,$y,$color );
>  imageline( $im,$x,$y2,$x2,$y2,$color );
>  imageline( $im,$x,$y,$x,$y2,$color );
>  imageline( $im,$x2,$y,$x2,$y2,$color );
> }
> function Square(int $x,int $y,int $size,int $pcolor )
> {
>  if ($size < 50)
>   break;
>  box($img,$x,$y,$x+$size,$y-$size,$pcolor );
>  Square($x-$size/4,$y+$size/4,$size/2,$pcolor );
>  Square($x+$size-$size/4,$y+$size/4,$size/2,$pcolor );
>  Square($x-$size/4,$y-$size+$size/4,$size/2,$pcolor );
>  Square($x+$size-$size/4,$y-$size+$size/4,$size/2,$pcolor );
> }
> Header ("Content-type: image/png");
> $img = imagecreate ($width,$height);
> $color = imagecolorallocate ($img,$tx_r,$tx_g,$tx_b);
> $pixel_color = imagecolorallocate ($img,$px_r,$px_g,$px_b);
> imagerectangle($img,0,0,$width,$height,$color);
> Square ( -1000,1000,2000,$pixel_color );
> imagepng($img);
> ?>
> 
> --------------------------------------------------------------------------------
> 
> Please give me a hand.
> thanks,
> Sincerely,
> GZM SoftwareŽ WebMaster
> [EMAIL PROTECTED]
> http://www.gzmsoftware.f2s.com
> 
> 


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]

Reply via email to