Hi can you advise if this is possible and how please?

I have a cmd line program which i want to run "PPP.exe test"
i then get a response saying i am in the program, then i need to send further perameters.
"set username Bill" - i will get a reponse, and then
"set password S3cr3t" - will get a response, and then
"sign-in" - i will get a response .. etc ...etc..

I know i can use exec ('c:\\WINDOWS\\system32\\PPP.exe test'); to run the program but what about sending the parameters and reading the response?


You want to run this script from remote desktop and pass the gathered info. over the network? Just for the sake of curiosity, what are you trying to achieved?


thanks for the reply.

No i want to run the application local on the webserver, using the username and password provided by the web user.
Sign in to the application which connects to another web service and send further commands like "get contacts list" and return the results into an array i can use in my php site.

Member Avatar


Is that any use to you?

I'm assuming that you want to run a command in windows cmd and get data into a locally hosted site?

I'm a little confused though - what is PPP.exe supposed to do? Extract data from somewhere after a few parameters have been supplied? What is supposed to happen then? This array data that you receive - where is it supposed to go? Into a DB / xml file?

If you want to create local php executables, have a look at php-gtk - but I doubt this is what you're looking for.