Re: crontab programmed with mysql ??
| From: | Tom Rogers | Date: | Tue, 03 Sep 2002 01:46:05 +0000 |
| Subject: | Re: crontab programmed with mysql ?? | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-114969@lists.php.net to get a copy of this message | ||
Hi,
Tuesday, September 3, 2002, 7:55:56 AM, you wrote:
aac> I'm looking for the approximate solution of mailing out (or doing anything
aac> else )
aac> timed by cron(tab) along with use of mysql as means of identification and
aac> storing
aac> of the dates in multiuser enviroment.
aac> Initial date and interval of recurring event is to be set up by a user.
aac> May you know some open source code as an example to do that or so?
aac> Thank you,
aac> Oleg
Probably the easiest way is to set up cron to call a php script every
5 mins or whatever the smallest interval you will need and have that
script run through your mysql tables looking for jobs to do. That way
you only need one cron job. If you are on unix type server the
simplest is to use lynx like this
5,10,15,20,25,30,35,40,45,50,55 * * * * /usr/bin/lynx -dump http://domain.com/chkjob.php 1> /dev/null 2> /dev/null
--
regards,
Tom