PCLZip library issue

Topics: User Forum
Mar 12, 2011 at 11:41 AM

Hello !

I don't have the php_zip.dll installed and tried to use the instruction

PHPExcel_Settings::setZipClass(PHPExcel_Settings::PCLZIP);

 

as instructed on the documentation (2.4.2.) to use the alternative (PCLZIP) to the ZipArchive class.

As a result, I've got the following error :

"Fatal error: Class 'ZIPARCHIVE' not found in C:\Program Files\wamp\www\master\Classes\PHPExcel\Writer\Excel2007.php on line 231"

Any idea ?

_____

php version 5.2.6

gd installed

xml installed

Coordinator
Mar 14, 2011 at 9:41 AM

Suggests that

PHPExcel_Settings::setZipClass(PHPExcel_Settings::PCLZIP);

is not working correctly. Test to see whether the return from this call is a boolean true or false.

You could also try calling

echo PHPExcel_Settings::getZipClass();

after setting it. to see that it contains the correct value

Mar 14, 2011 at 10:23 AM

I have the same problem

Fatal error: Class 'ZipArchive' not found in /home/*******/common/PHPExcel/Writer/Excel2007.php on line 225

Mar 14, 2011 at 11:45 AM
MarkBaker wrote:

Suggests that

PHPExcel_Settings::setZipClass(PHPExcel_Settings::PCLZIP);

is not working correctly. Test to see whether the return from this call is a boolean true or false.

The return from this call is: 1

You could also try calling

echo PHPExcel_Settings::getZipClass();

after setting it. to see that it contains the correct value

The result is:

PHPExcel_Shared_ZipArchive

Mar 14, 2011 at 1:33 PM

Yes it's return

PHPExcel_Shared_ZipArchive

BUT the is another error:

Fatal error: Class 'ZIPARCHIVE' not found in /home/******/common/PHPExcel/Writer/Excel2007.php on line 231

Coordinator
Mar 14, 2011 at 1:49 PM
This discussion has been copied to a work item. Click here to go to the work item and continue the discussion.