开发者

PHP ZipArchive - zip corrupt

On archiving more number of files , zip is returning a empty zip file which cannot be open and its corrupted.

When i try to pint Zip archive object , i got this:

ZipArchive Object

(

[status] => 5

[statusSys] => 2

[numFiles] => 84

[filename] => /root/zip/3810.zip

[comment] =>

)

The file is not even created.

for lesss number files it working fine .

ZipArchive Object ( [status] => 0 开发者_开发知识库[statusSys] => 0 [numFiles] => 0 [filename] => [comment] => )

What is this status and statusSys?

How can i debug?


Make sure after you've zipped everything that you ZipArchive::close() after you've added all of your files. If you don't use the close() function then the zip file is never created.

This would be done with:

$zip->close();
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜