If you are allowed, can you send me the defective zip to
[email protected]?
I've never run PHP on Windows, so I can't say what that might do, but it could affect the way paths are handled.
$zip->addDirectoryContent("example/","images");
should probably be changed to
$zip->addDirectoryContent("example" . DIRECTORY_SEPARATOR,"images");
I just ran this script on my own server:
<?php
error_reporting(E_ALL | E_STRICT);
ini_set('error_reporting', E_ALL | E_STRICT);
ini_set('display_errors', 1);
include_once("ZipStream.php");
$zip = new ZipStream("test3.zip");
$zip->addDirectoryContent("testData" . DIRECTORY_SEPARATOR,"test");
$rv = $zip->finalize();
?>
It correctly created a zip file with everything in the test directory, and its sub directories. test is in this case placed in the same dir as the ZipStream example script.
Though only 26 files, they make up about 74MB