首页 > 后端开发 > php教程 > 解决Zip PHP extension is not installed

解决Zip PHP extension is not installed

WBOY
发布: 2016-07-28 08:29:34
原创
3690 人浏览过

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>
登录后复制

安装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>
登录后复制

其他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教程有兴趣的朋友有所帮助。

相关标签:
来源:php.cn
本站声明
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系admin@php.cn
热门教程
更多>
最新下载
更多>
网站特效
网站源码
网站素材
前端模板