On Tuesday 27 January 2004 07:13, Stuart wrote:
> Hamid Hossain wrote:
> > Is there any good reference on how to use CRON (I mean on the
> > net)?
> >
> > I need to fire some PHP pages at scheduled time daily or weekly,
> > ... so on.
>
> http://www.google.com/search?q=cron+tutorial+php

depending on how you need them to fire off

a) if cron is on the same machine as the php script, then write the 
script as a command-line php script
http://www.php.net/manual/en/features.commandline.php

b) if cron is on a different machine, create a normal web php script 
with some sort of security and use lynx -dump to call it from cron
lynx -dump https://user:[EMAIL PROTECTED]/iben1Bj7s1N/sEg4gIh6G.php

either way add the job to the /etc/crontab file
man 5 crontab
<minute> <hour> <day of month> <month> <day of week> <user> <command>
ie
27 2 * * * bob php4 -q /usr/local/scripts/update.php

at 2:27am everyday, run 'php4 -q /usr/local/scripts/update.php' as 
the user bob

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to