I am trying to install imagemagic php extension under WampServer 2.
I've downloaded and installed ImageMagick . I've chosen ImageMagick-6.8.8-10-Q16-x86-dll.exe
I've downloaded the php extension.
I've moved the dll extension I just downloaded to C:\wamp\bin\php\php5.4.16\ext\
I've altered php.ini (accessed it through wamp tray icon > right-click > PHP > php.ini) and added "extension=php_imagick.dll", without the quotes, to the extensions lists.
I restarted Apache. Not noticing the extension displayed on the PHP extensions list from the tray icon, I restarted the wampserver. ImageMagick extensions now shows enabled on the list.
However, I cannot use it. Doing a quick test returns "Fatal error: Class 'Imagick' not found". In the phpinfo() shows only that the imagemagick has been added to env variables.
when I try to test the imagick :
$im = new imagick( 'test.jpg' ); // resize by 200 width and keep the ratio $im->thumbnailImage( 200, 0); // write to disk $im->writeImage( 'test_thumbnail.jpg' );
I get the error:Fatal error: Class 'imagick' not found
What am I doing wrong? I'm working with win7 32 bit, phph 5-4-16 and apache2
To enable Imagick for your website, go to your Site Tools -> Dev -> PHP Manager. Click the PHP Extensions tab and find the entry for the “imagick” extension in the list that appears. Then click the Change value button (pencil icon), select the On radio button for Status and save the changes.
Navigate to Home - Software - Module Installers, then click on the Manage button next to PHP Pecl. In the next screen, select the required PHP version, then click Apply. You can now enter “imagick” in the Install a PHP Pecl field, and click the Install Now button.
php -m | grep imagick
.sudo apt-get remove --purge php5-imagick && sudo apt-get install php5-imagick
Regards
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With