locked
[PHP][Web Apps] Install imagick php enstension to web app RRS feed

  • Question

  • Hi!

    I tried to install imagick php enstension on azure web sites.

    I have follow to guideline https://azure.microsoft.com/en-us/documentation/articles/web-sites-php-configure/

    But it not working for Imagick.

    I use .dll from https://pecl.php.net/package/imagick/3.1.2/windows.

    And when i put like  $Img = new \Imagick; i have Fatal error: Class 'Imagick' not found in...

    Any idea?

    Thanks!



    Wednesday, July 29, 2015 2:33 PM

Answers

  • Hi,

    Please upload phpinfo.php file to azure website to test whether the imagick extension has been installed, like the following screenshot:

    I have use a custom PHP runtime to install this extension successfully, the article you provide is a good resource, please have a look at this part: "How to: Use a custom PHP runtime", you need to pay attention to the following:

    1) please download the no thread safe version at: https://pecl.php.net/package/imagick/3.1.2/windows, and also need to match the PHP version

    2) If use your customer PHP runtime, please don't forget to change the extension dir path.

    3) please copy the php_imagick.dll to the ext folder and other 8 dlls in the php folder

    Best Regards,

    Jambor


    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click HERE to participate the survey.

    Friday, July 31, 2015 3:33 AM

All replies

  • Hello MedvedevIvan,

    Could you confirm that Imagick is loaded via the PHP Info Page? or running php -i from the Kudu Debug Console.

    If you can't see Imagick in the list, configure php errors via the .user.ini file (log_errors=1), then check the log file in d:\home\logFiles\php_errors.log

    You may also want to confirm that you are using the right dll for the very of PHP you have configure in Web App.

    Thanks,

    Cory


    Cory Fowler Windows Azure MVP http://blog.syntaxc4.net

    Wednesday, July 29, 2015 4:29 PM
  • Thanks!

    Now i check the php_errors.log, and i have error message:

    "PHP Warning:  PHP Startup: Unable to load dynamic library 'd:\home\site\ext\php_imagick.dll' - The specified module could not be found. in Unknown on line 0"

    But i use .dll from official website. Hmm..

    I was success install mongo and memcache, but the imagick i cant.

    What next?


    Wednesday, July 29, 2015 4:38 PM
  • Hi,

    Please upload phpinfo.php file to azure website to test whether the imagick extension has been installed, like the following screenshot:

    I have use a custom PHP runtime to install this extension successfully, the article you provide is a good resource, please have a look at this part: "How to: Use a custom PHP runtime", you need to pay attention to the following:

    1) please download the no thread safe version at: https://pecl.php.net/package/imagick/3.1.2/windows, and also need to match the PHP version

    2) If use your customer PHP runtime, please don't forget to change the extension dir path.

    3) please copy the php_imagick.dll to the ext folder and other 8 dlls in the php folder

    Best Regards,

    Jambor


    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click HERE to participate the survey.

    Friday, July 31, 2015 3:33 AM
  • you mentioned - 3) please copy the php_imagick.dll to the ext folder and other 8 dlls in the php folder

    However there is no way for you to copy 8 dll files to the PHP folder on the Azure Website. Please let me know how can you do it?

    Thanks.

    Tuesday, December 1, 2015 2:21 PM