Problem using exec() in Win2K

From: Date: Mon, 15 Oct 2001 19:19:49 +0000
Subject: Problem using exec() in Win2K
Groups: php.windows 
Request: Send a blank email to php-windows+get-9862@lists.php.net to get a copy of this message
Good Afternoon, This is the first time I've had to use exec() in a site I've written in PHP and I'm having a little trouble getting the syntax right to do what I need. This is on a W2K Server box with PHP 4.04, IIS 5.0 and MySQL 3.23. I need to execute a command as if I was in a cmd.exe window. The line I need to execute looks like this: # Splus /Batch c:\Statman\Sscripts\batch$cartid.ssc # This is a batch file that invokes Splus 6 runs the script and closes itself. We've tested it from a command prompt and it works. It does not return any output. The script performs a comparison in Splus and generates a gif image of the results in a specified folder which I then use later in another page. Below is what I used to call it from PHP but it dies everytime. # exec("c:\\cmd.exe>Splus /Batch c:\\Statman\\Sscripts\\batch$cartid.ssc") or die("<p>Couldn't execute Splus Script"); print "<p>Running SPlus Scripts to create report."; # I believe my syntax is wrong and need a little advise as to how to fix it. Any help is appeciated. Thanks. -------------------------- Robert Trembath Internet Technology Manager e|robert@ishoptech.com

« previous php.windows (#9862) next »