tags:

views:

290

answers:

2

Hello,

I have a ubuntu server. How can I zip files through executing a command line to zip from my php script

I want to zip the file because the file sizes are too big and zipping it through php will cause more load on server.

Thank You.

A: 

exec, system, fork, - any of the commands can you help execute command line programs with varying levels of control (blocking, non-blocking)

Mr-sk
what should be the command if i want to zip all the files in a particular folder?
Shishant
A: 

If you don't need compression I would suggest to look into tar instead of zip as it should be quicker and will result in one file same as zip but without CPU time taken to process the archive

LukeP