Re: [PHP Install] ERROR using imagegif

From: Date: Fri, 05 May 2006 23:54:46 +0000
Subject: Re: [PHP Install] ERROR using imagegif
References: 1  Groups: php.install 
Request: Send a blank email to php-install+get-17299@lists.php.net to get a copy of this message
Hello, From my research on the manual page (http://www.php.net/manual/en/function.imagegif.php) if you give a 2nd argument to Imagegif() it writes the image to disk rather than sending it to the browser. Your browser is giving you that error message because the image data goes into the file and the browser gets an empty image. regards, Peter --- Vinod Rao <vinodiitg@gmail.com> wrote: > Hi , > I'm developing php script to generate an image having text written on it. > And I have to save that image to one file file.gif , so that I can use that > image in the next html file. > The extract of the code is where error comes : > > header("Content-type: image/gif"); > $filename = "./vinod/file.gif"; > $fh = fopen($filename,"w"); > fclose($fh); > chmod($filename, 0777); // octal; correct value of mode > Imagegif($myImage,$filename); > > It gives error message on the browser : > The image "http://192.168.1.18/cool1.php" cannot be > displayed, because it > contains errors. > when I removed 2nd argument of Imagegif , then no error comes. > Kindly resolve the problem. > > Regards, > Vinod. > ____________________________________ > Vinod Rao > Member of Technical Staff > Terrawiz Software Technologies Pvt. Ltd. > Bangalore > URL :: http://www.terrawiz.com > Mobile : +91-9886741620 > ____________________________________________________ On Yahoo!7 Dating: It's free to join and check out our great singles! http://www.yahoo7.com.au/personals ____________________________________________________ On Yahoo!7 Dating: It's free to join and check out our great singles! http://www.yahoo7.com.au/personals

« previous php.install (#17299) next »