php gd extension
I get a Call to undefined function imagefontwidth()
error in my php file. I configured php with an extensi开发者_如何学运维ons dir and enabled the gd library. But I still see the error.Am I missing something?
Thanks.
Refer to phpinfo() and make sure everything was installed correctly. imagefontwidth() should be available since v4, so I do not think the version should be an issue. Other than that the only thing I could think of would be to reinstall the extensions.. Or:
From PHP Manual
Check the php.ini file. Make sure the php_gd.dll isnt commented out. Restarting apache should result in the image functions working.
Ok, I found the solution. Initially I had uncommented the 'extension_dir = "ext"' line in php.ini. This did not work. I then put in a absolute path instead of 'ext'. So, the line now looks like 'extension_dir = "c:/php/ext"'. This works. I don't know why the default value wont work.
精彩评论