I Have A Problem About extract the zip file with PHP
I try many shared script on the web
but it still doesn't work
the last script i try is this script :
<?php
$zip = new ZipArchive;
$res = $zip->open('data.zip');
if ($res === TRUE) {
$zip->extractTo('/extract/');
$zip->close();
echo 'woot!';
} else {
echo 'doh!';
}
?>
I am always get the else condition when the script is run ,
I've tried replacing the data.zip
and the /extract/
path to complete path http://localhost/basedata/data.zip
and http://localhost/basedata/extract/
but I still got the else condition , Anyone can help me?
Here Is My whole script and the zip file http://www.mediafire.com/?c49c3xdxjlm58ey