You are here: PHP exec() and Zipping Upload file in Windows « PHP Programming Language « IT news, forums, messages
PHP exec() and Zipping Upload file in Windows

Posted by johnny on 12/20/06 01:57

I have the following code. What I need is to zip the file
(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=
"c:\web\upload\someFile".

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация