For each web host can be set to periodically script launching. For each web host can be set max. 3 entries of cron, the shortest possible period is 1 hour. If you have activated additional service CRON+, you can set up to 10 entries with the shortest intervals of 5 minutes.
Cron to each webhosting you can manage in the customer administration in webhosting detail.
After the list of scripts for execution, where you can edit or delete entries, the following form for adding/editing entries
After the creation/editing of entries, Cron is calculating the date of the next possible execution.
Important information
- By cron is possible to execute URL addresses that are directed to our servers on appropriate webhosting. You can not use another URL or execute some commands on the command line.
- It is not possible to guarantee that cron will execute the script exactly at that minute.
- We recommend in your PHP script to use a system of locks for the case that the cron job could be launched multiple times due to some technical problem, which may be undesirable for your application
- It is not possible to execute PHP script, that requires HTTP authentication – solve it by inserting some additional URL parameter with a password, without which you will not run the script directly
- Do not limit the execution of PHP script by source IP address. We can not guarantee that the IP address of the server does not change. Solve it also by another secret parameter in the URL.
Possible settings
CRON name
Name of the Cron for your needs
Execute 1x per
Period, after which the script will be executed.
- do not run – CRON is deactivated
- 1 hour – each hour (in 0 minutes)
- 2 hours – every even hour (in 0 minutes)
- 4 hours – every four hours, starting from midnight (in 0 minutes)
- 6 hours – every six hours, starting from midnight (in 0 minutes)
- 12 hours – daily at midnight and noon (in 0 minutes)
When is activated Optional service CRON+, there are also available intervals of 5 minutes, 15 minutes and 30 minutes.
Hours of the day (from/to)
Within hours, from when to when to run the script every day.
- whole day – 0 – 23
- part of the day – eg. 11-15 or such. 22-2 (from midnight to 2 and from 22 to midnight)
- only 1x per day at a certain time – eg. 11 – 11
Days of the Week
Which days the script is (or not) have to run (Monday to Sunday).
Date (from/to)
The range of dates, from when to when the script has to run, in the format YYYY-MM-DD. These settings are optional, or you can specify only one of the dates. Date “to” must not be less than today’s date and may not be less than the date “from”.
It is not filled either one of the dates, there are no date restrictions. If it is entered date “from” only, the script will be executed from this date without expiration. If it is entered date “to” only, the script will be executed from now until this date. If both are filled, the script will be executed in this range.
Script URL
Address of script that will be periodically executed.
- subdomain – the domain of the third level
- domain – second-level domain directed to your webhosting
- script – the script name with possible parameters in the url
With these settings you can create for example such address: http://www.your-site.cz/cron/script.php?data=123.
In order to perform the script, it is necessary to satisfy the following conditions:
- domain of script must be directed to our webhosting
- script must exist at the given address
- according to the configuration should be possible to determine the date of the next startup
Examples of settings
Every hour, on weekdays from 8h to 17h, to December 23, 2010
Execute 1x per: 1 hour
Hours of the day: from 8 to 17
Days of the week: Monday to Friday
Date: to 2010-12-23
At 15h, every day, from 1 January 2011
Execute 1x per: 1 hour
Hours of the day: from 15 to 15
Days of the week: Monday to Sunday
Date: od 2011-01-01
Every 2 hours, excluding 6-16h every day
Execute 1x per: 2 hours
Hours of the day: od 16 do 6
Days of the week: pondělí až neděle
Date: