Jump to content

Unzip A File


The Little Guy

Recommended Posts

For some reason, this isn't unzipping

 

the value of $location when It gets to this point is:

/home/brend123/hostbox.us/subdomains/test/test.zip

 

Is there an extra step I need to do, or is there something wrong?

(I have had it working before on a different project in the past)

 

Code:

if($_POST['unzip']==1){
$location = '/home/brend123/hostbox.us/subdomains/'.$subName.'/'.$_GET['dr'].'/'.$filename;
$location = str_replace('//','/',$location);
exec("unzip '$location'",$arr);
unlink($location);
}

Link to comment
https://forums.phpfreaks.com/topic/107467-unzip-a-file/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.