On Thursday 26 October 2006 6:48 pm, Prathaban Mookiah wrote: > Hello List, > > I have a situation where, when the user logs into the system (Apache 2/PHP > 5.1/Win XP) the php script should activate a Java program to run in the > background. This program will keep running in the background while > everytime the user requests something, the subsequent php scripts > communicates with this Java program on a preassigned port. (This is for > controlling a robot I descibed in on of my earlier mails) > > My questions are: > > 1. How do I make the Java program to keep running even after the PHP script > terminates. In Linux I would have easily done using '&' - how about > windows? > > 2. What is the safest way to do it? > > > Thanks in advance. > > Prathap > > P.S - Richard & Tedd - I appreciate your comments on my previous issue.
Does the Java program HAVE to be started by a script? I've worked in a few places that had desktop apps that would just run on startup, or a service, and then the webserver/php would communicate to it since it's already running. The downside to that is manual intervention when the program stops. Although... you could probably to an exec() and if it was installed as a service you should be able to run "net start <appname>' (or something like that. I haven't kept up on your previous post so I may be completely wrong ;) -- Ray Hauge Application Development Lead American Student Loan Services www.americanstudentloan.com 1.800.575.1099 -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php