PHP system() fails on WinZipSE

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
ronnyzmanbarzell
Forum Newbie
Posts: 3
Joined: Wed Jun 23, 2010 10:48 am

PHP system() fails on WinZipSE

Post by ronnyzmanbarzell »

Good Morning,


I am having a problem with system() on PHP (Windows) running the WinZip Self-Extractor. Here's a relevant code snippet ($zip and $base have both been properly defined):

system("\\progra~1\\winzip\\wzzip.exe $zip $base.*");
system("\\progra~1\\winzip~1\\winzipse.exe -y -o $zip");

When this runs I find a zip file corresponding to $zip, verifying the first system() succeeded. However, there is no exe file which should be the output from the second system() call. What's more, WinZipSE (the process corresponding to the second system() call) ends up stuck in the background without terminating. Everything works when I type in the contents of system (expanding $zip) from the command line.

Any help would be greatly appreciated.


Thanks!
ronnyzmanbarzell
Forum Newbie
Posts: 3
Joined: Wed Jun 23, 2010 10:48 am

Re: PHP system() fails on WinZipSE

Post by ronnyzmanbarzell »

Hey,


I ended up using 7-zip instead and everything works. Thanks in advance to anyone who looked into this.


Take Care.
Post Reply