[nycphp-talk] loop
FB`
fb at intldef.org
Fri Dec 20 11:27:51 EST 2002
I see what you mean..
what about using a value set in another way to start/stop the loop - for ex,
reading the contents of a file every so many loops and continuing or not
based on that.
this file would then be altered by the $run=false script, and the currently
running script could exit when in encounters the changed value...
FB`
----- Original Message -----
From: "Brian" <brian at preston-campbell.com>
To: "NYPHP Talk" <talk at nyphp.org>
Sent: Friday, December 20, 2002 11:16 AM
Subject: Re: [nycphp-talk] loop
> That would merely start a non-running instance of the same script, as
opposed
> to killing the one that is looping on the server.
>
> I'm looking into Hans' suggestion of
>
> >You could have PHP kill itself in various way, if this helps:
>
> >http://www.php.net/manual/en/ref.posix.php
> >http://www.php.net/manual/en/ref.pcntl.php
>
> I have to look into how PHP was compiled and if these will be possible.
Back
> to the limits of an embedded system -- can't compile anything.
>
> Brian
>
>
> On Friday 20 December 2002 10:48 am, FB` wrote:
> > How about passing the $run variable for the while loop (as someone else
> > mentioned) through the browser, via get?
> >
> > so you could go to
> > http://tinyembedded/control.php?run=true
> > or
> > http://tinyembedded/control.php?run=false
> > to start and stop, respectively...
> >
> > FB`
> >
> >
> > ----- Original Message -----
> > From: "Brian" <brian at preston-campbell.com>
> > To: "NYPHP Talk" <talk at nyphp.org>
> > Sent: Friday, December 20, 2002 7:35 AM
> > Subject: Re: [nycphp-talk] loop
> >
> > > The script will specifically not time out. I don't want it to. The
> > > issue is that it is running on a tiny embedded server (see
> > > http://www.boa.org) running php3lite, a reduced version of php for
just
> > > such a system. I opened a browser three days ago, started the script,
> > > and then closed the browser. If I need to kill the process I am not
> > > sure how to do it other than restarting the server although I can
> > > probably end it with [kill -1 php] in ssh. Since these are not normal
> > > circumstances, I was curious if there might be another way to end the
> > > process.
> > >
> > > Brian
> > >
> > > On Thu, 2002-12-19 at 23:09, CHUN-YIU LAM wrote:
> > > > I think what he meant to say is why the webserver did not timeout..
> > > >
> > > > Matthew
> > > >
> > > > ----Original Message Follows----
> > > > From: Adam Fields <fields at surgam.net>
> > > > Reply-To: talk at nyphp.org
> > > > To: NYPHP Talk <talk at nyphp.org>
> > > > Subject: Re: [nycphp-talk] loop
> > > > Date: Thu, 19 Dec 2002 17:35:24 -0500
> > > > Received: from mc6-f2.law1.hotmail.com ([65.54.252.138]) by
> > > > mc6-s7.law1.hotmail.com with Microsoft SMTPSVC(5.0.2195.5600); Thu,
19
> >
> > Dec
> >
> > > > 2002 14:48:06 -0800
> > > > Received: from parsec.nyphp.org ([66.250.131.26]) by
> >
> > mc6-f2.law1.hotmail.com
> >
> > > > with Microsoft SMTPSVC(5.0.2195.5600); Thu, 19 Dec 2002
14:47:33 -0800
> > > > Received: from nyphp.org (parsec.nyphp.org [66.250.131.26])by
> > > > parsec.nyphp.org (8.12.6/8.12.6) with ESMTP id gBJMZOSt066445;Thu,
19
> >
> > Dec
> >
> > > > 2002 17:35:24 -0500 (EST)(envelope-from listmaster at nyphp.org)
> > > > Message-Id: <200212192235.gBJMZOSt066445 at parsec.nyphp.org>
> > > > X-Paralist-Archived:
> >
> > <http://nyphp.org/list/paralist_archive.php?L_mid=1971>
> >
> > > > X-List-Software: Paralist 0.6
> > > > List-ID: <nyphptalk.nyphp.org>
> > > > List-Owner: <mailto:listmaster at nyphp.org>
> > > > List-Archive: <http://nyphp.org/list/paralist_archive.php?L_lid=1>
> > > > List-Subscribe: <http://nyphp.org/list/>
> > > > List-Unsubscribe: <http://nyphp.org/list/>
> > > > Organization: New York PHP
> > > > X-Mailer: Paramail 0.5
> > > > Return-Path: listmaster at nyphp.org
> > > > X-OriginalArrivalTime: 19 Dec 2002 22:47:34.0102 (UTC)
> > > > FILETIME=[9EDAD760:01C2A7B0]
> > > >
> > > > On Thu, Dec 19, 2002 at 04:27:15PM -0500, Brian wrote:
> > > > > I am currently using a script to move a webcam at certain time
> >
> > intervals.
> >
> > > > The
> > > >
> > > > > script never times out and uses the following to run
indefinitely:
> > > > >
> > > > > for (;;) {
> > > > > [camera instuctions]
> > > > > }
> > > > >
> > > > > Anyone know the principal behind this snippet and why it works?
I
> >
> > have
> >
> > > > not
> > > >
> > > > > been able to find any information on the subject.
> > > >
> > > > This is clearly documented in the online manual:
> > > >
> > > > http://www.php.net/manual/en/control-structures.for.php
> > > >
> > > >
> > > > --
> > > > - Adam
> > > >
> > > > -----
> > > > Adam Fields, Managing Partner, fields at surgam.net
> > > > Surgam, Inc. is a technology consulting firm with strong background
in
> > > > delivering scalable and robust enterprise web and IT applications.
> > > > http://www.adamfields.com
> > > >
> > > >
> > > >
> > > >
> > > >
> > > > _________________________________________________________________
> > > > Add photos to your e-mail with MSN 8. Get 3 months FREE*.
> >
> >
http://join.msn.com/?page=features/featuredemail&xAPID=42&PS=47575&PI=7324&
> >D I=7474&SU=
> >
> >
http://www.hotmail.msn.com/cgi-bin/getmsg&HL=1216hotmailtaglines_addphotos_
> >3 mf
> >
> >
> >
> >
> >
> >
> >
> >
> >
> >
> >
> >
> >
> >
> >
> >
> >
> >
> >
>
>
>
>
> --- Unsubscribe at http://nyphp.org/list/ ---
>
>
>
More information about the talk
mailing list