?
Solved

ImageMagick PHP 5.5 on IIS 7.5

Posted on 2014-07-31
17
Medium Priority
?
2,403 Views
Last Modified: 2014-08-04
I'm trying to get this setup working. Here is what I've done.

Installed ImageMagick-6.8.9-6-Q16-x86-dll.exe from imagemagick.org.

Copied the DLL From php_imagick-3.1.2-5.5-nts-vc11-x86.zip to the php ext directory.  Downloaded from here http://windows.php.net/downloads/pecl/releases/imagick/3.1.2/

Added this line(s) to the php.ini
[PHP_IMAGICK]
extension=php_imagick.dll


Did an IIS reset. Try to access it via a test script, and I get Class 'Imagick' not found, and it isn't showing up in phpinfo.

From other web searchs it looks like most struggle with getting the php, program, and dll versions matched up but I think I've done that. PHP is 5.5 VC11 x86. I installed the latest x86 version of the program, and installed the 5.5 NTS x86 VC11 version of the DLL. I'm at a loss.
0
Comment
Question by:bhieb
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 9
  • 5
  • 3
17 Comments
 

Author Comment

by:bhieb
ID: 40232253
Some more info. Ok so i went back to the drawing board, visited a site that others mentioned. http://www.peewit.fr/imagick/ Since that site valiates to IM 6.8.4 i loaded ImageMagick-6.8.4-0-Q8-x86-dll.exe  .

Now the ImageMagick section shows up on phpinfo, but when I run this. It returns not installed class doesn't exist. So I'm closer, but still no joy.

if (!extension_loaded('imagick'))
    echo 'imagick not installed';
	
if( class_exists("Imagick") )
	{
	echo 'class exists';
	}
	else
	{
	echo 'class does not exist';
	}

Open in new window

0
 
LVL 15

Expert Comment

by:Insoftservice
ID: 40232450
INSTALL STEPS TAKEN

To install IMagick on Windows XP (PHP 5.2.x)

    download and install ImageMagick-6.5.8-7 Q16-windows-dll.exe http://www.imagemagick.org/download/binaries/ImageMagick-6.5.8-7-Q16-windows-dll.exe

    download php_imagick_dyn-Q16.dll from http://valokuva.org/outside-blog-content/imagick-windows-builds/080709/

    copy DLL to [PHP]/extension dir and rename it to php_imagick.dll

    You have to edit your php.ini file and add the new extension:

    extension=php_imagick.dll

    Save php.ini and restart Apache server. (If necessary, restart Windows)

    phpinfo() should show imagick enabled.
0
 

Author Comment

by:bhieb
ID: 40232641
Thanks for the try, but that is pretty dated info since it is XP and php 5.2.  WIth broken download links to valokuva.  Not to mention I've already stated that all of that has been done, and it IS showing in phpinfo().
0
How Blockchain Is Impacting Every Industry

Blockchain expert Alex Tapscott talks to Acronis VP Frank Jablonski about this revolutionary technology and how it's making inroads into other industries and facets of everyday life.

 
LVL 15

Expert Comment

by:Insoftservice
ID: 40232656
good to hear that.
I hope you tried nearly same steps right? Except php version
0
 

Author Comment

by:bhieb
ID: 40232660
Yes the exact same steps but with updated versions from http://www.peewit.fr/imagick/  to match my php, vc installation.
0
 
LVL 15

Expert Comment

by:Insoftservice
ID: 40232699
Ok so my comment was help full for you to resolve your issue beside version issue.
Best of luck for your project
0
 
LVL 58

Expert Comment

by:Gary
ID: 40232789
Ok so my comment was help full for you to resolve your issue beside version issue.
Ignorance is bliss

Did you select Add to System Path when installing?
Did you completely restart IIS
What do the IIS logs say
0
 
LVL 58

Expert Comment

by:Gary
ID: 40232838
You said in the opening question it wasn't showing in phpinfo and then later you said it is???
0
 

Author Comment

by:bhieb
ID: 40232843
Yes I did do that add of the path. I even added the system variable per this link.
http://refreshless.com/blog/imagick-pecl-imagemagick-windows 

I did an iisreset, and actually have since rebooted the server since it could have been the enviro variable. I found my IIS logs and I don't see anything in them, and the php logs are clear too.
0
 

Author Comment

by:bhieb
ID: 40232844
Yes now it is, my 2nd post I tried an older version and got past that.
0
 

Author Comment

by:bhieb
ID: 40232860
Since we did get side tracked a little here is my current state.

Got the DLL from here. http://windows.php.net/downloads/pecl/deps/
ImageMagick-6.8.9-1-vc11-x86.zip

Install package from here. http://ftp.sunet.se/pub/multimedia/graphics/ImageMagick/binaries/
ImageMagick-6.8.9-1-Q16-x86-dll.exe  

dll is in the \ext directory with the extension=php_imagick.dll added to the php.ini.

phpinfo() shows the section. But the test code returns not installed.

The path is set, and the new environ variable is there too.
0
 
LVL 58

Accepted Solution

by:
Gary earned 2000 total points
ID: 40233023
ImageMagick has to be the hardest thing to install

Remove what you have

Can you get the dll from here
http://www.peewit.fr/imagick/

From the sunset link grab the 6.8.4 version
0
 

Author Comment

by:bhieb
ID: 40233047
Same imagick not installed error. I even made sure to double check the path and environ variable.  Shows fine in phpinfo() though so that is weird.
0
 
LVL 58

Expert Comment

by:Gary
ID: 40233063
It may be a false negative, try actually using the plugin on an image.
Something like

$image = new Imagick('someimage.jpg');
0
 

Author Comment

by:bhieb
ID: 40239167
Still no luck. We've decided to go a different route.  At this point even if I get it working, I'd be hesitant to put such a flaky product into production. I'll toss you the points since you were the most helpful Gary.
0
 
LVL 58

Expert Comment

by:Gary
ID: 40239191
The GD library can do a lot of things and it's part of PHP
0
 

Author Comment

by:bhieb
ID: 40239209
Yep that is what we use primarily, we wanted the ability to create a thumbnail from a PDF or convert from PDF > JPG> thumbnail for publishing PDF brochures. It is such a niche in our environment, that we can do it manually.
0

Featured Post

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

If you don't have the right permissions set for your WordPress location in IIS, you won't be able to perform automatic updates. Here's how to fix the problem.
If you are a web developer, you would be aware of the <iframe> tag in HTML. The <iframe> stands for inline frame and is used to embed another document within the current HTML document. The embedded document could be even another website.
The viewer will learn how to dynamically set the form action using jQuery.
This tutorial will teach you the core code needed to finalize the addition of a watermark to your image. The viewer will use a small PHP class to learn and create a watermark.
Suggested Courses

719 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question