CodeIgniter Forums
unable to use imagemagick processing - Printable Version

+- CodeIgniter Forums (https://forum.codeigniter.com)
+-- Forum: Archived Discussions (https://forum.codeigniter.com/forum-20.html)
+--- Forum: Archived Development & Programming (https://forum.codeigniter.com/forum-23.html)
+--- Thread: unable to use imagemagick processing (/thread-45598.html)



unable to use imagemagick processing - El Forum - 09-27-2011

[eluser]Unknown[/eluser]
After developing an image gallery using gd2 on my local machine, but I had problems on the production server, where the rotate function wasn't working. So I switched to Imagemagick on the production server, but resizing and rotating won't work.

Imagemagick is installed, running and it works fine from the terminal.

I set the image_library and library path in my config file:

Code:
$config['image_library'] = 'imagemagick';
$config['library_path'] = '/usr/bin/convert';

and passed it to the config array:

Code:
$config = array(
    'image_library' => $this->config->item('image_library', 'gallery'),
    'library_path' => $this->config->item('library_path', 'gallery')
);

The command CI generates looks like this:

Code:
/usr/bin/convert -quality 90 -rotate 270 "/path/photos/CIMG0025.JPG"
"/path/photos/_resampled/CIMG0025_preview.JPG" 2>&1

This also works from the terminal, so it should work with the image lib too.

I give up! Can anybody help me with this?