如何在 Windows 7 上安装 ImageMagick 以与 PHP 一起使用 (3)

2024-08-22php开发问题
13

本文介绍了如何在 Windows 7 上安装 ImageMagick 以与 PHP 一起使用 (3)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着跟版网的小编来一起学习吧!

问题描述

还有其他关于如何在 Windows 7 上安装 Imagick 的主题,但到目前为止对我没有帮助.(也许最近的版本出现了问题)

我已按照以下步骤安装:

  1. 下载并安装 ImageMagick

<块引用>

http://www.imagemagick.org/download/binaries/ImageMagick-6.8.8-1-Q16-x86-dll.exe

  1. 下载 php_imagick.dll 并复制到扩展目录 (c:xamppphpext)

<块引用>

http://www.peewit.fr/imagick/php55/vc11/x86/ts/php_imagick.dll

  1. 编辑 php.ini 文件并添加新的扩展名 (c:xamppphpphp.ini)

<块引用>

extension=php_imagick.dll

  1. 保存ini文件并重启Apache(必要时重启Windows)

  2. 启动 Apache 并运行测试

当我启动 Apache 时,我得到一个弹出框,显示:

<块引用>

程序无法启动,因为您的计算机中缺少 php5.dll.尝试重新安装程序以解决此问题.

紧随其后的是另一个:

<块引用>

PHP 启动:无法加载动态库 'C:xamppphpextphp_imagick.dll' - 找不到指定的模块.

根据 funtioneer 我怀疑某种编译错误.

现在我有 PHP 版本 5.5.6 (xampp 1.8.3) 和编译器 MSVC11,它与 php_imagick.dll 文件相同.

从源代码下载 ImageMagick 并自己编译是正确的方法吗?(以前从未在 Windows 中编译过)

解决方案

我尝试从 这里.那一个实际上与 http://www.peewit 的 php_imagick.dll(PHP 5.5.x 的 Imagick)一起使用.fr/imagick/.

这不是最新版本,但它有效.(即使不重新启动计算机)

There are other threads about how to install Imagick on Windows 7 but no help for me so far. (Maybe problems have came up with more recent versions)

I have followed these steps to install:

  1. Download and install ImageMagick

http://www.imagemagick.org/download/binaries/ImageMagick-6.8.8-1-Q16-x86-dll.exe

  1. Download php_imagick.dll and copy to extension dir (c:xamppphpext)

http://www.peewit.fr/imagick/php55/vc11/x86/ts/php_imagick.dll

  1. Edit php.ini file and add new extension (c:xamppphpphp.ini)

extension=php_imagick.dll

  1. Save ini file and restart Apache (if necessary, restart Windows)

  2. Start Apache and run test

When I start Apache i get a pop up box that displays:

The program can't start because php5.dll is missing from your computer. Try reinstalling the program to fix this problem.

Then directly after this comes another:

PHP Startup: Unable to load dynamic library 'C:xamppphpextphp_imagick.dll' - The specified module could not be found.

According to funtioneer I suspect some kind of compilation error.

Now I have PHP Version 5.5.6 (xampp 1.8.3) with compiler MSVC11 which is the same as for the php_imagick.dll file.

Is download ImageMagick from source and compile it on my own the right way to go? (have never compiled in Windows before)

解决方案

Instead of using the latest version I tried downloading ImageMagick-6.7.7-5-Q16-windows-dll from here. That one actually worked with the php_imagick.dll (Imagick for PHP 5.5.x) from http://www.peewit.fr/imagick/.

This is not the latest version but it worked. (even without restarting the computer)

这篇关于如何在 Windows 7 上安装 ImageMagick 以与 PHP 一起使用 (3)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持跟版网!

The End

相关推荐

PHP实现DeepL翻译API调用
DeepL的翻译效果还是很强大的,如果我们要用php实现DeepL翻译调用,该怎么办呢?以下是代码示例,希望能够帮到需要的朋友。 在这里需要注意,这个DeepL的账户和api申请比较难,不支持中国大陆申请,需要拥有香港或者海外信用卡才行,没账号的话,目前某宝可以...
2025-08-20 php开发问题
168

PHP通过phpspreadsheet导入Excel日期数据处理方法
PHP通过phpspreadsheet导入Excel日期,导入系统后,全部变为了4开头的几位数字,这是为什么呢?原因很简单,将Excel的时间设置问文本,我们就能看到该日期本来的数值,上图对应的数值为: 要怎么解决呢?进行数据转换就行,这里可以封装方法,或者用第三方的...
2024-10-23 php开发问题
287

mediatemple - 无法使用 codeigniter 发送电子邮件
mediatemple - can#39;t send email using codeigniter(mediatemple - 无法使用 codeigniter 发送电子邮件)...
2024-08-23 php开发问题
11

Laravel Gmail 配置错误
Laravel Gmail Configuration Error(Laravel Gmail 配置错误)...
2024-08-23 php开发问题
16

将 PHPMailer 用于 SMTP 的问题
Problem with using PHPMailer for SMTP(将 PHPMailer 用于 SMTP 的问题)...
2024-08-23 php开发问题
4

关于如何在 GoDaddy 服务器中使用 PHPMailer 设置 SMTP 的问题
Issue on how to setup SMTP using PHPMailer in GoDaddy server(关于如何在 GoDaddy 服务器中使用 PHPMailer 设置 SMTP 的问题)...
2024-08-23 php开发问题
17