1

I'am trying to read xlsx file, but I get this error:

Warning: ZipArchive::getFromName(): Invalid or unitialized Zip object in E:\wamp\www\test\Classes\PHPExcel\Reader\Excel2007.php on line 323

what this error mean?

3
  • And your complete code is? Nov 30, 2013 at 17:13
  • can you unzip the archive with other tools?
    – hek2mgl
    Nov 30, 2013 at 17:22
  • Do you have php_zip enabled? What version of PHP are you using?
    – Mark Baker
    Nov 30, 2013 at 20:01

1 Answer 1

3

I had the same error and it was due to improper permissions. Try doing a simple fopen() to make 100% sure you can read that file from the given directory. Also, make sure you can read that file successfully if it's in the same directory as your script so you know the file itself is okay.

1
  • 1
    I have the same error, but the permissions does not seem to be the issue for me. The file can be opened and read. Any other possible solutions?
    – Arya
    Dec 17, 2018 at 19:32

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.