Aller au contenu principal Aide Panneau de contrôle

A+   A-

Logiciel serveur «  

Documentation : cron.php

cron.php - Launch periodic jobs

This script includes all scripts bound to the id 'tick'.

This is achieved through the loading of hook definitions, if any. See control/scan.php for more information on hooks.

It can be launched either from the command line, making it suitable to be invoked from a crontab, or remotely through the web, for example through wget and the like.

This architecture allows for different kinds of background processing:

-  Integrated to front-end processing - This is the default mode of operation. Ticks are triggered randomly when regular pages have been generated. This easy setup is very nice, except that most servers are buffering data nowadays, meaning surfers may have to wait for the end of background processing to get their page. Simple, but not that good for surfer satisfaction.

-  Linked to cron - Launching this script from the crontab is everything that is required for YACS background processing. A period of time of 10 minutes is suitable in most situations. This script takes care of time, and will wait for a minimum of 5 minutes between ticks anyway.

-  Linked to wget - If you don't have access to the crontab, you may install another computer to launch this script remotely, through the web. For example, add an entry to the crontab of your own computer to launch the wget command with the URL of this script as parameter (e.g., http://a_nice_server/yacs/cron.php).

To enable running from anywhere the script change the current directory to where it is located. Alternatively, you can set the environment variable 'YACS_HOME' to point to the installation path of YACS.

For example:
set YACS_HOME = "c:/public/yacs"


The script ensures a minimum delay of 5 minutes between successive ticks.

This script is a reference file of this system.

Voir aussi :

Licence : GNU Lesser General Public License

Auteurs :


tn