Click to See Complete Forum and Search --> : gd library on Win2K
stoop
06-16-2001, 04:30 AM
I want to install the gd library to be able to generate images in my PHP code. Unfortunateky I can't compile the support for it as we are not allowed compilers on production internet facing serves for security.
Is there a pre-compiled binary/dll available that I can just copy into the PHP directory?
Thanks.
mithril
06-18-2001, 12:50 AM
Stoop,
There is indeed. Grab the big Win32 distro (about 4.5 mb for 4.0.5) from http://www.php.net/downloads.php. This archive contains the gd extension as well as many others. HTH,
Cheers,
Geoff A. Virgo
stoop
06-18-2001, 06:55 AM
Thanks Geoff, I'm grabbing it now.
Stoop
stoop
06-19-2001, 08:01 AM
Geoff, turns out I had installed that large distribution inb the first place but I reinstalled just in case.
However I get the same error:
Fatal error: Call to undefined function: imagecreate() in c:\program files\apache\htdocs\simplegraph.php on line 5
Any idea what that could be?
Stoop
mithril
06-19-2001, 11:17 AM
Stoop,
Could be any number of things I s'pose. Are you loading in any other extensions? If so, have you had any problems with them? One likely candidate is that you may not have the extension_dir directive in php.ini pointing to the correct path of your extensions. However, my version of Apache (1.3.20 on Win98 SE) pops up error windows if it can't find the path to an extension so you'd probably already know about that. Next place to look is are you actually loading php_gd.dll either by uncommenting "extension=php_gd.dll" in php.ini or by a dl("php_gd.dll"); in your script body. If all this checks out, call phpinfo() and look to see if a GD section exists in the output. Have you tried using any of the other gd methods, imagecreatefromjpeg() for example? Any errors there? Finally, is PHP installed as an Apache module or in CGI mode? Can't think why that should make a difference, but you never know. It would probably help if you posted a sample of the code you're using. Let me know how it goes. HTH,
Cheers,
Geoff A. Virgo
stoop
06-20-2001, 07:27 AM
That was it!! I removed the semi-colon, it's working fine now.
Thanks a lot.
Stuart
PHP Builder
Copyright WebMediaBrands Inc. All Rights Reserved.