Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Laravel - Imagick not installed

using Laravel and trying to work on image upload using Imagine.

The issue is that I get the error stating:

Imagine \ Exception \ RuntimeException

Imagick not installed
Open: /Applications/MAMP/htdocs/laravelcms/vendor/imagine/imagine/lib/Imagine/Imagick/Imagine.php

{
/**
* @throws RuntimeException
*/
public function __construct()
{
if (!class_exists('Imagick')) {
throw new RuntimeException('Imagick not installed');
}

I followed this guide, and correctly created all the folders and files etc as stated:

http://creolab.hr/2013/07/image-manipulation-in-laravel-4-with-imagine/

I have also checked the the Imagick folder with all files etc is in the correct location.

Any help?

Thanks, Craig.

like image 272
Lovelock Avatar asked Oct 15 '14 21:10

Lovelock


2 Answers

After some research, I found that MAMP 3 comes with Imagick pre-installed but not enabled by default.

Simply edit the php.ini file and search for:

;extension=imagick.so

Remove the ';' before it.

like image 86
Lovelock Avatar answered Oct 07 '22 04:10

Lovelock


Also for all other: do not forget that artisan will probably use separate php.ini, so will need to include extension=imagick.so there as well.

like image 41
gorodezkiy Avatar answered Oct 07 '22 05:10

gorodezkiy