Zubrag.com
June 17, 2019, 01:06:26 PM *
Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length
 
   Home   Help Search Login Register  
Pages: [1]
  Print  
Author Topic: how to unzip files in php  (Read 24367 times)
zubrag
Administrator
Hero Member
*****
Posts: 788


WWW
« on: January 30, 2007, 04:57:53 PM »

If you are on Unix/Linux the easiest way would be:

<?php

$filename = escapeshellarg ($_GET['filename']);
$destination_folder = escapeshellarg($_GET['destination_folder']);

echo shell_exec ("unzip -ou $filename -d $destination_folder");

?>

This will not work if safe_mode is on

Logged
basheer
Newbie
*
Posts: 6


« Reply #1 on: August 27, 2009, 11:20:38 PM »

how to write a php code for upload and  :odownload a file
Logged
sifulffc
Newbie
*
Posts: 1


« Reply #2 on: May 31, 2010, 02:17:54 PM »

Recently I've been developing things with quite a bit of automation. PHP generates files amazingly fast, but using ftp_put and FTP'ing files into the server can be incredible slow if you have a massive amount of files. It's much faster to upload a single zipped file. I know you could easily zip the files yourself, but alas, laziness makes me write more code and save those valuable seconds.

Mazda Miata Parts
Logged
boomsticks53
Newbie
*
Posts: 8


« Reply #3 on: June 20, 2010, 09:03:43 PM »

I never had any problem in unzip unless its password  protected
Logged

albertjooger
Newbie
*
Posts: 9


« Reply #4 on: April 13, 2011, 08:25:20 AM »

Its can just be occur because of your losting password.
Logged

P
Pages: [1]
  Print  
 
Jump to:  

Powered by SMF 1.1.11 | SMF © 2006-2009, Simple Machines LLC