By Martin Bean
I have a Droplet running Ubuntu 14.04. I tried to install the GD library using sudo apt-get install php5-gd and it seemed to install fine. I restarted the Apache2 service, but my image upload script still gives this error:
Call to undefined function imagecreatefrompng()
Are there any additional steps I need to take before the GD library is available to my PHP scripts?
This textbox defaults to using Markdown to format your answer.
You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!
This question was answered by @jak:
If you’re using a custom php.ini, rather than the default setup, you’ll need to ensure the extension is loaded with a setting like…
extension=gd.soYou can find your php.ini file location that’s in use with a call to php_info()
This comment has been deleted
This comment has been deleted
Get paid to write technical tutorials and select a tech-focused charity to receive a matching donation.
Full documentation for every DigitalOcean product.
The Wave has everything you need to know about building a business, from raising funding to marketing your product.
Stay up to date by signing up for DigitalOcean’s Infrastructure as a Newsletter.
New accounts only. By submitting your email you agree to our Privacy Policy
Scale up as you grow — whether you're running one virtual machine or ten thousand.
Sign up and get $200 in credit for your first 60 days with DigitalOcean.*
*This promotional offer applies to new accounts only.