Rumah > pembangunan bahagian belakang > tutorial php > 解决Zip PHP extension is not installed

解决Zip PHP extension is not installed

WBOY
Lepaskan: 2016-07-28 08:29:34
asal
3666 orang telah melayarinya

LAMP环境编译安装,其中php版本为5.6.8,php-fpm已经做成了系统服务,OS版本为CentOS6.x系列

<code>[RuntimeException]                                                        
  The Zip PHP <span>extension</span><span>is</span><span>not</span> installed. Please install it <span>and</span><span>try</span> again.</code>
Salin selepas log masuk

安装php,zip模块

<code>cd /usr/<span>local</span>/src
wget http:<span>//pecl.php.net/get/zip-1.12.4.tgz</span>
tar xvf zip<span>-</span><span>1.12</span><span>.4</span><span>.</span>tgz <span>-C</span> /usr/<span>local</span><span>/</span>
cd /usr/<span>local</span>/zip<span>-</span><span>1.12</span><span>.4</span>
/usr/<span>local</span>/php/bin/phpize
<span>.</span>/configure <span>--</span><span>with</span><span>-php</span><span>-config</span><span>=</span>/usr/<span>local</span>/php/bin/php<span>-config</span>
make <span>&&</span> make install
安装完成后会在/usr/<span>local</span>/php/lib/php/extensions<span>/</span>下生成no<span>-debug</span><span>-non</span><span>-zts</span><span>-xxxxxxxx</span>的目录,其中包含了zip<span>.</span>so
vim /etc/php<span>.</span>ini或者vim /usr/<span>local</span>/php/etc/php<span>.</span>ini
添加一行
extension<span>=</span>/usr/<span>local</span>/php/lib/php/extensions/no<span>-debug</span><span>-non</span><span>-zts</span><span>-</span><span>20131226</span>/zip<span>.</span>so
重新加载或重启fpm
service php<span>-fpm</span> restart</code>
Salin selepas log masuk

其他zip版本可查看以下连接
http://pecl.php.net/package/zip

').addClass('pre-numbering').hide(); $(this).addClass('has-numbering').parent().append($numbering); for (i = 1; i ').text(i)); }; $numbering.fadeIn(1700); }); });

以上就介绍了 解决Zip PHP extension is not installed,包括了方面的内容,希望对PHP教程有兴趣的朋友有所帮助。

Label berkaitan:
sumber:php.cn
Kenyataan Laman Web ini
Kandungan artikel ini disumbangkan secara sukarela oleh netizen, dan hak cipta adalah milik pengarang asal. Laman web ini tidak memikul tanggungjawab undang-undang yang sepadan. Jika anda menemui sebarang kandungan yang disyaki plagiarisme atau pelanggaran, sila hubungi admin@php.cn
Tutorial Popular
Lagi>
Muat turun terkini
Lagi>
kesan web
Kod sumber laman web
Bahan laman web
Templat hujung hadapan