RE: [PHP-WIN] executing an external program
| From: | Scott Hurring | Date: | Tue, 30 Apr 2002 19:52:04 +0000 |
| Subject: | RE: [PHP-WIN] executing an external program | ||
| Groups: | php.windows | ||
| Request: | Send a blank email to php-windows+get-13424@lists.php.net to get a copy of this message | ||
Also, try system() if you want to see the output
of the called program (http://php.net/system)
PS: The online help system is your friend. :)
---
Scott Hurring
Systems Programmer
EAC Corporation
ScottH@eac.com
Voice: 201-462-2149
Fax: 201-288-1515
> -----Original Message-----
> From: Mike Flynn [mailto:mike@mikeflynn.net]
> Sent: Saturday, April 27, 2002 4:48 PM
> To: Rainer Bruch; php-windows@lists.php.net
> Subject: Re: [PHP-WIN] executing an external program
>
>
> Some things to think about are:
> 1. http://www.php.net/manual/en/function.exec.php
> 2. If you are going to use backslashes in a string, you need
> to escape
> them, so the sample code your "specialist" gave you would
> need to be changed:
> ><?
> >shell_exec('c:\\programme\\microsoft office\\office\\winword.exe');
> >?>
> Otherwise PHO would see \p, \m, \o, \w escape codes.
>
> -Mike
>
> At 06:45 PM 4/27/02 +0200, Rainer Bruch wrote:
> >i am new in using and understanding php. need help in
> following issue:
> >opening (executing) an external program (not a file) like
> "winword.exe" with
> >php4.
> >my system-configuration:
> >- windows 2000
> >- php4 1.1.1
> >- winword execution program-path is:
> >"c:\programme\micosoft office\office\winword.exe"
> >
> >please, will somebody out there will help me with the
> complete php-code
> >like:
> ><?
> >"code to execute the winword-program";
> >?>
> >
> >i have asked a so called specialist who gave the following
> (not functioning,
> >no error message) code:
> ><?
> >shell_exec("c:\programme\microsoft office\office\winword.exe");
> >?>
> >
> >thanks to all who will help me
> >rainer
> >
> >
> >
> >--
> >PHP Windows Mailing List (http://www.php.net/)
> >To unsubscribe, visit: http://www.php.net/unsub.php
>
>
> -- Mike Flynn --
> mike @ mikeflynn . net
> home => work => home => shop => home [adbusters]
>
>
> --
> PHP Windows Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>