Hopefully, despite similar question titles, this isn't a duplicate issue.
I've installed ImageMagick-6.7.5-6-Q16-windows-dll.exe
.
I have php_imagick_dyn-Q16.dll
renamed to php_imagick.dll
in PHP's ext
directory.
I have extension=php_imagick.dll
in my php.ini
.
I try to run a basic test: php -r "var_dump(class_exists('Imagick'));"
.
I get this error:
PHP Startup: imagick: Unable to initialise module
Module compiled with module API=20060613
PHP compiled with module API=20090626
These options must match.
CLI has stopped working.
Windows can check online for a solution to the problem.
> Check online for a solution and close the program
> Close the program
What have I done wrong?
- First install : http://imagemagick.org/script/binary-releases.php#windows
- Download : http://www.sk89q.com/2010/03/vc6-windows-binaries-for-imagick-2-3-0/
- Choose the TS one
- Open your php.ini file
Add this line :
extension=php_imagick.dll
Restart your apache server
open php_info()
Now your imagick lib is ready to use.
This works for me.
来源:https://stackoverflow.com/questions/9365758/how-to-install-imagemagick-on-windows-7-2