Re: [PHP] Can I make a process run in background?

2007-11-06 Thread Per Jessen
Robert Cummings wrote: > On Tue, 2007-11-06 at 19:33 +0100, Per Jessen wrote: >> Jason Pruim wrote: >> >> > Actually, what you are looking for is an eggdrop bot which is >> > written in TCL. PHP in my humble opinion was not designed to handle >> > something like that as it requires realtime proce

Re: [PHP] Can I make a process run in background?

2007-11-06 Thread Robert Cummings
On Tue, 2007-11-06 at 20:23 +0100, Luca Paolella wrote: > > This can be done quite easily using shared memory and/or a database to > > share data between the scripts. > Really? could you give me a little briefing about this method? I'll give an example using the DB as the sharing mechanism. So you

Re: [PHP] Can I make a process run in background?

2007-11-06 Thread Luca Paolella
This can be done quite easily using shared memory and/or a database to share data between the scripts. Really? could you give me a little briefing about this method? Actually, what you are looking for is an eggdrop bot which is written in TCL. PHP in my humble opinion was not designed to handl

Re: [PHP] Can I make a process run in background?

2007-11-06 Thread Robert Cummings
On Tue, 2007-11-06 at 19:33 +0100, Per Jessen wrote: > Jason Pruim wrote: > > > Actually, what you are looking for is an eggdrop bot which is written > > in TCL. PHP in my humble opinion was not designed to handle something > > like that as it requires realtime processing. Someone correct me if >

Re: [PHP] Can I make a process run in background?

2007-11-06 Thread Robert Cummings
On Tue, 2007-11-06 at 18:05 +0100, Luca Paolella wrote: > Hi, > > I'm very grateful for your help (thanks to everybody!), but maybe I > didn't explain myself correctly, I'm sorry. What I need is the bot to > log onto the server and, being logged as a user, to send some > periodic messages on

Re: [PHP] Can I make a process run in background?

2007-11-06 Thread Per Jessen
Jason Pruim wrote: > Actually, what you are looking for is an eggdrop bot which is written > in TCL. PHP in my humble opinion was not designed to handle something > like that as it requires realtime processing. Someone correct me if > I'm wrong but that isn't what PHP was designed to do was it? I

Re: [PHP] Can I make a process run in background?

2007-11-06 Thread Jason Pruim
Actually, what you are looking for is an eggdrop bot which is written in TCL. PHP in my humble opinion was not designed to handle something like that as it requires realtime processing. Someone correct me if I'm wrong but that isn't what PHP was designed to do was it? There are many eggdrop

Re: [PHP] Can I make a process run in background?

2007-11-06 Thread Luca Paolella
Hi, I'm very grateful for your help (thanks to everybody!), but maybe I didn't explain myself correctly, I'm sorry. What I need is the bot to log onto the server and, being logged as a user, to send some periodic messages on a channel ( Hello!) while listening for events and reacting cons

Re: [PHP] Can I make a process run in background?

2007-11-06 Thread Nathan Nobbe
if youre running linux, you might also want to consider disown. -nathan

Re: [PHP] Can I make a process run in background?

2007-11-06 Thread Wolf
You could CRON the script, write a simple bash script that polls the server and if the php script is not running, restarts it. * * * * * * /path/to/php Wolf Jim Lucas <[EMAIL PROTECTED]> wrote: > oops, didn't mean to reply off list. SORRY LIST! > > here is what I said. > > This metho

Re: [PHP] Can I make a process run in background?

2007-11-06 Thread Jim Lucas
oops, didn't mean to reply off list. SORRY LIST! here is what I said. This method will work until you log out, when you log out all your background processes are killed. If it were to be a CLI and you wanted it to run constantly and you manually wanted to control it, I would use "screen". S

Re: [PHP] Can I make a process run in background?

2007-11-06 Thread Per Jessen
Jim Lucas wrote: > This method will work until you log out, when you log out all your > background processes are killed. man nohup. /Per Jessen, Zürich -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Can I make a process run in background?

2007-11-06 Thread Jim Lucas
Per Jessen wrote: Luca Paolella wrote: I want the bot to run a process in background (a periodic message, for example) while listening for events (like a user joining a channel or using a certain command) and consequentially executing the corresponding functions, is it possible? and how? Writ

Re: [PHP] Can I make a process run in background?

2007-11-06 Thread Per Jessen
Luca Paolella wrote: > I want the bot to run a process in background (a periodic message, > for example) while listening for events (like a user joining a > channel or using a certain command) and consequentially executing the > corresponding functions, is it possible? and how? Write a PHP CLI sc

Re: [PHP] Can I make a process run in background?

2007-11-05 Thread Paul Scott
On Mon, 2007-11-05 at 19:20 +0100, Luca Paolella wrote: > I want the bot to run a process in background (a periodic message, > for example) while listening for events (like a user joining a > channel or using a certain command) and consequentially executing the > corresponding functions, i

[PHP] Can I make a process run in background?

2007-11-05 Thread Luca Paolella
Hi, Before I start explaining my problem I'd like to say one thing: I'm aware that php isn't the best-suited language for what I'm trying to do (an IRC bot), but unfortunately by now it's the only way I have for various reasons; I want the bot to run a process in background (a periodic me