[ Index ] |
|
Code source de Horde 3.1.3 |
1 #!/usr/bin/php 2 <?php 3 /** 4 * $Horde: horde/scripts/crond,v 1.4.10.5 2006/06/16 08:24:29 jan Exp $ 5 * 6 * Copyright 2003-2006 Charles J. Hagenbuch <chuck@horde.org> 7 * 8 * See the enclosed file COPYING for license information (LGPL). If you 9 * did not receive this file, see http://www.fsf.org/copyleft/lgpl.html. 10 */ 11 12 require_once 'Horde/CLI.php'; 13 require_once 'Horde/Scheduler.php'; 14 15 // Make sure no one runs this from the web. 16 if (!Horde_CLI::runningFromCLI()) { 17 exit("Must be run from the command line\n"); 18 } 19 20 // Load the CLI environment - make sure there's no time limit, init 21 // some variables, etc. 22 Horde_CLI::init(); 23 24 // Get an instance of the cron scheduler. 25 $daemon = &Horde_Scheduler::singleton('cron'); 26 27 // Now add some cron jobs to do, or add parsing to read a config file. 28 // $daemon->addTask('ls', '0,5,10,15,20,30,40 * * * *'); 29 30 // Start the daemon going. 31 $daemon->run();
titre
Description
Corps
titre
Description
Corps
titre
Description
Corps
titre
Corps
Généré le : Sun Feb 25 18:01:28 2007 | par Balluche grâce à PHPXref 0.7 |