ID: 39537 Updated by: [EMAIL PROTECTED] Reported By: hscheidegger at zumbach dot ch -Status: Assigned +Status: Feedback Bug Type: Zip Related Operating System: Windows XP PHP Version: 5.2.0 Assigned To: pajoye New Comment:
I cannot reproduce it on windows and unix, using CLI, apache2 , IIS or CGI. What's the status after the extractTo call? Can you paste it here? do a var_dump($zip); after having called it. Previous Comments: ------------------------------------------------------------------------ [2006-11-16 21:27:43] hscheidegger at zumbach dot ch When I do: $zip->extractTo('/my/destination/dir/'); every file in the archive is extracted. When I do: $zip->extractTo('/my/destination/dir/', 'pear_item.gif'); no file is extracted and no error message appear. When I do: $zip->extractTo('/my/destination/dir/', array('pear_item.gif','testfromfile.php')); no file is extracted and no error message appear. ------------------------------------------------------------------------ [2006-11-16 18:33:41] [EMAIL PROTECTED] What is the actual result you get? ------------------------------------------------------------------------ [2006-11-16 18:23:02] hscheidegger at zumbach dot ch use the script from the php documentation found here: http://ch2.php.net/manual/en/function.ziparchive-extractto.php <?php $zip = new ZipArchive; $res = $zip->open('test_im.zip'); if ($res === TRUE) { $zip->extractTo('/my/destination/dir/', array('pear_item.gif', 'testfromfile.php')); $zip->close(); echo 'ok'; } else { echo 'failed'; } ?> ------------------------------------------------------------------------ [2006-11-16 18:04:31] [EMAIL PROTECTED] Thank you for this bug report. To properly diagnose the problem, we need a short but complete example script to be able to reproduce this bug ourselves. A proper reproducing script starts with <?php and ends with ?>, is max. 10-20 lines long and does not require any external resources such as databases, etc. If the script requires a database to demonstrate the issue, please make sure it creates all necessary tables, stored procedures etc. Please avoid embedding huge scripts into the report. ------------------------------------------------------------------------ [2006-11-16 17:55:52] hscheidegger at zumbach dot ch Description: ------------ extractTo() method only works when extracting every file from the Zip archive. Single and multiple file extraction does not work. Win XP Apache 2.2.3 PHP latest snap, ApacheModul CLI doesn't work neither. Regards, H-P Scheidegger ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=39537&edit=1