Forums / Setup & design / imagemagick convert parameters do not work?

imagemagick convert parameters do not work?

Author Message

alex t

Friday 28 November 2003 7:45:46 am

hi
I use convert. that does fine when setting this in the image.ini.append:
ConvertExecutable=convert

now when I try any parameter, e.g. for creating a border like this:
ConvertExecutable=convert -border 1

I get the following error:

Failed executing: "/usr/local/bin/convert -border 1" -geometry "600x600>" var/porsche/storage/reference/image//php4RKn3Z.jpg jpg:var/porsche/storage/variations/image/p/h/p//php4RKn3Z_600x600_282.jpg, Err: , Ret: 127

any idea about that? when I do the same (a simple convert -border 1 to any image) on the command line, the conversion works fine.

the two " " cause the failure. where and why are they set? also, the foto is not in ./reference/image but in ./original/image
maybe the upload did not work correct because of the " "? :-)

setting the image.ini.append back to
ConvertExecutable=convert

you can see at least the correct convert call:

Failed executing: /usr/local/bin/convert -geometry "600x600>" var/pors......

(error still occurs because the image is missing in that directory)

maybe it´s a php issue? system info:

Version
3.2-3 (3.2 release 3)
SVN revision
3893

Extensions

PHP
Version
4.3.2

Extensions
xml, tokenizer, standard, session, posix, pcre, overload, mysql, ctype, apache

Safe mode is off.
Basedir restriction is off.
Global variable registration is on.
File uploading is enabled.
Maximum size of post data (text and files) is 32M.
Script memory limit is .
Maximum execution time is 30 seconds

Database
Type
mysql
Charset
iso-8859-1

regards
/alex

Marco Zinn

Saturday 29 November 2003 5:14:05 am

Hi Alex,
when you upload images, the original is stored in var/original/image. At the same time, a "reference image" of this images is create in var/reference/image. This usually is some "usuable" size like 800x600, while you original image may be larger, if it comes from a digital camera for example.
As you assume, the problem is the first pair of quotes. The second pair of quotes (-geometry "600x600>" ) is needed, because without quotes, the > character would mean an "output redirection" for the operating system. So, th 600x600> must be in quotes.

You CAN try this:
http://ez.no/developer/ez_publish_22/forum/general/error_while_uploading_an_image_problem_solution , but I guess, that this will always give your very large image variations.
Also see this bug report http://ez.no/developer/ez_publish_3/bug_reports/convert_command_with_custom_parameters_fails, which describes your problem and notes some Variable ConvertParameters.... but i don't know, if this was introduced yet.

Note: Version 3.3 has a new image system... but i did not test this yet! Maybe you want to have a look at the beta 1 release.

Marco
http://www.hyperroad-design.com

alex t

Monday 01 December 2003 9:19:15 am

ok let's try 3.3

thanks for answer :)