Link to home
Start Free TrialLog in
Avatar of fox_statton
fox_statton

asked on

Create a zip or other archive on a server

Hi all,
Does anyone know of a way to create a zip or another archive on a server with the contents of a folder in it?

For example

zip("/home/server/files","/home/server/file.zip");

which would get all the folders and files in /home/servers/files and create a zip called file zip containing them all....
Avatar of Roonaan
Roonaan
Flag of Netherlands image

you could try running gzip

exec('gzip ..arguments');

-r-
Avatar of Robin Hickmott
Robin Hickmott

use the system() function to execute a pkzip command or similar on the folder.
ASKER CERTIFIED SOLUTION
Avatar of hernst42
hernst42
Flag of Germany image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
No comment has been added to this question in more than 21 days, so it is now classified as abandoned.

I will leave the following recommendation for this question in the Cleanup topic area:
   Split: Roonaan {http:#18102118} & rhickmott {http:#18102122} & hernst42 {http:#18102898}

Any objections should be posted here in the next 4 days. After that time, the question will be closed.

Huji
EE Cleanup Volunteer