Generate excel, run the test locally and get the error Class ‘ZipArchive’ not found.
Solution:
In the window system:
In the php.ini file, remove the semicolon “;” in front of extension=php_zip.dll, change zlib.output_compression = Off to zlib.output_compression = On, and restart apache
2. Under linux system:
To recompile php_zip.dll
1 cd /usr/src 2 wget http://pecl.php.net/get/zip 3 tar -zxvf zip 4 cd zip-1.x.x 5 phpize 6 . /configure 7 make 8 sudo make instal
After installation, record the location of zip.so on the screen, e.g. /usr/local/lib/php/extensions/zip.so
In php.ini, add extension = /usr/local/lib/php/extensions/zip.so, then change zlib.output_compression = Off to zlib.output_compression = On
Finally restart apache: service httpd restart
Similar Posts:
- [Solved] PHP Fatal error: Class ‘mysqli’ not found in xxx
- /usr/bin/ld: cannot find -lz
- [Solved] Failed to decode response: zlib_decode(): data error
- zlib.h:no such file or directory
- [Solved] Php5.6.30 environment error call to undefined function imagecreate() compile and install GD Library
- PHP extensions Install Error: PHP Startup: Invalid library (maybe not a PHP library) ‘zlib.so’ in Unknown
- Cannot load php7apache2 to server
- Mac Error: Connection to `ssl://pecl.php.net:443′ failed [How to Solve]
- Can’t find PHP headers in /usr/include/php The php-devel package is required for use of this command.
- [Solved] Wget Error: The certificate of ‘XXX’ is not trusted