From: kmteoh at hotmail dot com Operating system: w2k PHP version: 5.2.9RC1 PHP Bug Type: Zip Related Bug description: still not working after trying most versions
Description: ------------ can't get the ziparchive to add files correctly. tried different version of php_zip.dll same thing happen, and it generates funny files. followed instructions in #46985, used php_zip.dll version 5.2.5.5, 5.2.8.8, 5.2.9.9 all not work. it only work in cli but not browser (isapi). it generates files like test.zip.b03252 and test.zip.a03252 for me instead of actual test.zip. i renamed to test.zip then tried to extract but crc error. Reproduce code: --------------- <?php $zip = new ZipArchive; if ($zip->open('test.zip') === TRUE) { $zip->addFile('index.txt', 'newname.txt'); $zip->close(); echo 'ok'; } else { echo 'failed'; } ?> Expected result: ---------------- should be able to open the test.zip with winzip or winrar easily Actual result: -------------- crc error. -- Edit bug report at http://bugs.php.net/?id=47324&edit=1 -- Try a CVS snapshot (PHP 5.2): http://bugs.php.net/fix.php?id=47324&r=trysnapshot52 Try a CVS snapshot (PHP 5.3): http://bugs.php.net/fix.php?id=47324&r=trysnapshot53 Try a CVS snapshot (PHP 6.0): http://bugs.php.net/fix.php?id=47324&r=trysnapshot60 Fixed in CVS: http://bugs.php.net/fix.php?id=47324&r=fixedcvs Fixed in CVS and need be documented: http://bugs.php.net/fix.php?id=47324&r=needdocs Fixed in release: http://bugs.php.net/fix.php?id=47324&r=alreadyfixed Need backtrace: http://bugs.php.net/fix.php?id=47324&r=needtrace Need Reproduce Script: http://bugs.php.net/fix.php?id=47324&r=needscript Try newer version: http://bugs.php.net/fix.php?id=47324&r=oldversion Not developer issue: http://bugs.php.net/fix.php?id=47324&r=support Expected behavior: http://bugs.php.net/fix.php?id=47324&r=notwrong Not enough info: http://bugs.php.net/fix.php?id=47324&r=notenoughinfo Submitted twice: http://bugs.php.net/fix.php?id=47324&r=submittedtwice register_globals: http://bugs.php.net/fix.php?id=47324&r=globals PHP 4 support discontinued: http://bugs.php.net/fix.php?id=47324&r=php4 Daylight Savings: http://bugs.php.net/fix.php?id=47324&r=dst IIS Stability: http://bugs.php.net/fix.php?id=47324&r=isapi Install GNU Sed: http://bugs.php.net/fix.php?id=47324&r=gnused Floating point limitations: http://bugs.php.net/fix.php?id=47324&r=float No Zend Extensions: http://bugs.php.net/fix.php?id=47324&r=nozend MySQL Configuration Error: http://bugs.php.net/fix.php?id=47324&r=mysqlcfg