hey, where's the GD library installed to? right now my mediawiki points to /usr/bin/convert but it isn't resizing my photos.
Printable View
hey, where's the GD library installed to? right now my mediawiki points to /usr/bin/convert but it isn't resizing my photos.
http://us2.php.net/gd
The gd library is compiled into php.
convert is an imagemajick CLI program
If you have no other option and cannot use the GD library built into PHP, you need to contact support@glowhost.com about enabling the insecure 'exec' command.
Use the helpdesk to submit trouble tickets / support issues. support@glowhost.com is no longer used...
... ooops....
I dont fully understand the problem so ignore this if it isnt relevent!
But..
An oscommerce install i have auto thumbnails all of my images and if i want i can set a parameter to convert gifs to jpegs on all my images. I dont fully understand how this is done as i didnt write this particular script. However having a quick look through the php files it makes reference to 'GD Library' all over the place so i guess it is using it!?
That being said i dont have any special access on that account and it all works without a hitch, Magic!
Sorry i couldnt be more helpful than that!
It's a little different than that, I think. My MediaWiki is just asking for the location of GD, and when it can't find it, it returns this error:
In my config file it asks the location of GD, which filled out by deault is /usr/bin/convert. Is there another place where the library could be located, or is there a way that I should notate the directory differently?Code:Error creating thumbnail: /usr/bin/convert: Unrecognized option (-thumbnail).
Well as John Marc said convert is part of ImageMagick so if your config file says to use GD and it returns and ImageMagick error it sounds like a bug in the script to me.
I'd check with mediawiki on that part.
This is what I have in one of my mediawiki LocalSettings.php files and it thumbnails fine:
## To enable image uploads, make sure the 'images' directory
## is writable, then set this to true:
$wgEnableUploads = false;
$wgUseImageResize = true;
$wgUseImageMagick = true;
$wgImageMagickConvertCommand = "/usr/local/bin/convert";
but you might try
$wgImageMagickConvertCommand = "/usr/bin/convert";
Assuming imagemagick is installed on the server this error looks like a nightmare! Just doing a quick search on google brings up pages and pages devoted to this error and everyone seems to have a different solution to solve it!
What server are you on? I think the problem is that -thumbnail may not be supported on the cPanel version of imagemagick. I think if you replace it with -geometry it should work
Well it looks like I'm using ImageMagick and not GD. However, the same problem applies... when i changed it to /usr/local/bin/convert I get a different error:
Error creating thumbnail: sh: line 1: /usr/local/bin/convert: No such file or directory
So it looks like the old directory was correct. it just doesn't recognize -thumbnail. How is this fixed?
As I said, you can replace the -thumbnail with -geometry in your code.Quote:
How is this fixed?
Otherwise, IM needs to be upgraded on your server. If it is a shared server, then unfortunately, the risk of an upgrade messing with everyone elses system will make it hard for the request to be considered.
Ian,
We have upgraded ImageMagick on your server and you can use /usr/local/bin/convert with the option -thumbnail and it won't throw any error messages.
Works now. Thanks a bunch!
No problem. Glad to hear that it worked out ;)
Well, there ya go. Thats why I work here. These guys are great! On a Sunday no less!