RE: [PHP-INSTALL] Error using GD with php 5.0...
| From: | Jens Rosenthal | Date: | Sun, 24 Aug 2003 09:55:13 +0000 |
| Subject: | RE: [PHP-INSTALL] Error using GD with php 5.0... | ||
| References: | 1 | Groups: | php.install |
| Request: | Send a blank email to php-install+get-11758@lists.php.net to get a copy of this message | ||
Hi,
Seem's a bit off-topic to me ;-)
I'd suggest putting an "ImagePNG ($im);" at the end of xour file, and I
think it is much better then... Without it, you're simply creating the
image, but you don't send it to the client (=browser)
Greetings,
Jens
-----Original Message-----
From: Rajeev Ramdas [mailto:rajeevramdas@netscape.net]
Sent: Sunday, August 24, 2003 2:07 AM
To: php-install@lists.php.net
Subject: [PHP-INSTALL] Error using GD with php 5.0...
Hi All...
I have php 5.0 beta running on windows 2000.
I am trying to use the GD library to build some graphs.
I am using the following sample code
<?php
header ("Content-type: image/png");
$im = imagecreate (300,300);
$white = imagecolorallocate ($im,255,255,255);
$blue = imagecolorallocate ($im,0,0,255);
?>
And it gives me the following error in mozzila.
The image "http://myserver.mydomain.com/php/image.php"
cannot be
displayed because it contains errors.
When i run phpinfo, it does say the GD (bundled 2.0.15) is enabled . I
have copied php.ini to c:\winnt. uncommented the line that has
php_gd2.dll. And copied php_gd2.dll to c:\winnt\drivers.
Can someone tell me how i can troubleshoot this further and make it
work.
Thanks for your time and help.
-Rajeev.
__________________________________________________________________
McAfee VirusScan Online from the Netscape Network. Comprehensive
protection for your entire computer. Get your free trial today!
http://channels.netscape.com/ns/computing/mcafee/index.jsp?promo=393397
Get AOL Instant Messenger 5.1 free of charge. Download Now!
http://aim.aol.com/aimnew/Aim/register.adp?promo=380455