我最近搬到了 MediaTemple 并按照他们的知识库文章安装了 ImageMagick 和IMagick。
没有错误并且 phpinfo() 显示模块已正确安装。
当我尝试通过 PHP 在 JPG 图像上使用 IM 时,出现此错误
Uncaught exception 'ImagickException' with message 'no decode delegate for this image format
/home/149263/domains/wer.com/html/images/pictures/post/tmp/original/' @ error/constitute.c/ReadImage/544' in /nfs/c10/h04/mnt/149263/domains/wer.com/html/application/controllers/post.php:301
Stack trace:
#0 /nfs/c10/h04/mnt/149263/domains/wer.com/html/application/controllers/post.php(301): Imagick->__construct('/home/149263/do...')
#1 [internal function]: Post->filter('punch')
#2 /nfs/c10/h04/mnt/149263/domains/wer.com/html/system/core/CodeIgniter.php(359): call_user_func_array(Array, Array)
#3 /nfs/c10/h04/mnt/149263/domains/wer.com/html/index.php(217): require_once('/nfs/c10/h04/mn...')
#4 {main} thrown in /nfs/c10/h04/mnt/149263/domains/wer.com/html/application/controllers/post.php on line 301
然而convert -list configure
返回
DELEGATES bzlib djvu fontconfig freetype gvc jpeg jp2 lcms openexr png rsvg tiff wmf x11 xml zlib
并identify -list format
返回
JPEG* JPEG rw- Joint Photographic Experts Group JFIF format (62)
JPG* JPEG rw- Joint Photographic Experts Group JFIF format
所以看起来安装是正确的。
ImageMagick 6.7.7-0 2012-05-22
imagick module version 3.1.0RC1
任何建议如何解决这个问题?