The installation for ImageMagick and PHP-imagick is pretty simple for Linux Plesk server. Following the steps to install them on Plesk server:
ImageMagick Installation:
[[email protected] ~]# yum install ImageMagick
[[email protected] ~]# yum install ImageMagick-devel
PHP-imagick Installation:
[[email protected] ~]# yum install gcc
[[email protected] ~]# yum install make automake
[[email protected] ~]# yum install php-pear
[[email protected] ~]# yum install php-devel
[[email protected] ~]# pecl install imagick
This will create a imagick.so file under /usr/lib/php/modules/ on 32-bit operating machine and /usr/lib64/php/modules/imagick.so on 64-bit operating system. You will have to add this extension in your global (loaded PHP condifuration file). You will need to add following line to enable extension:
extension = “imagick.so”
After adding the above extension, you will need to restart your Apache service. You can use the following command to restart it:
[[email protected] ~]# /etc/init.d/httpd restart
Now, you can verify your installation using the following commands:
For ImageMagick:
[[email protected] ~]# which convert
Output should be as follow:
/usr/bin/convert
For PHP-imagick:
[[email protected] ~]# php -m | grep imagick
Output should be as follow: