Do you have a question? Post it now! No Registration Necessary. Now with pictures!
- Posted on
December 20, 2006, 1:57 am
rate this thread
(c:\web\upload\someFile) to d:\web\someFile.zip.
$cmd = 'c:\zip\zip.exe '. $movedFile. ' '. $finalFile;
exec( $cmd, $cmd_output );
File is being uploaded by the apache server, but it's not being zipped.
My guess "\", escaping, is causing problem in windows path. Do I also
have to escape the $movedFile content? Forexample $movedFile=
- Hendri Kurniawan
December 20, 2006, 2:49 am
Re: PHP exec() and Zipping Upload file in Windows
If the string is already in a variable, PHP won't take account of the
(coz it's already escaped).
Anyway, PHP only escape strings that are surrounded by double quote (")
not single quote (')