Page 1 of 1
Re: Convert PDF to thumbnail JPG - no result
Posted: 2007-07-01T11:51:24-07:00
by Bonzo
The first code example looks correct; try it with a pdf on your server first to see if it works ?
I assume the images directory is CHMOD 777.
P.S. When using something like image.psd[2] for the 3rd layer in a psd file I put 'image.psd[2]' in my php code. I am unsure what you would want to use; that may be your problem.
Re: Convert PDF to thumbnail JPG - no result
Posted: 2007-08-22T13:28:39-07:00
by hina
try this :
exec("convert '$pdfhost[0]', '-resize', '150x100', '$pdfthumb'");
Re: Convert PDF to thumbnail JPG - no result
Posted: 2007-08-22T23:30:53-07:00
by anthony
If this is your first PHP IM program, back off a bit and make sure you get IM working with PHP first.
See IM examples API and scripting...
http://www.imagemagick.org/Usage/api/#php
Often the PHP environment is not as complete as a command line environment due to apathetic system Administration. Especually things like PATH and LD_LIBRARY_PATH. Also check for error output. The 'exec 2>&1'' in the test scripts re-direct errors output by the command to the normal output of PHP so you can see them. That would be for testing only.
Any one have a better IM command line caller, that includes nice handling and reporting of error output?