Open the cpanel management backend, under the "Advanced" option there is a "Clock Guardian Job", as shown below, click to enter. The settings page has three options: Cron Email (notification email address, this email address will be notified every time the scheduled execution succeeds or fails), Add New Cron Job (add a new scheduled task), and Current Cron Jobs (currently existing scheduled tasks). The main thing is to set the Add New Cron Job option, as shown below: The command shown in the figure is executed every 5 minutes: command: "php /home/piaoyi.org/public_html/cron.php" means: Executing the command in the form of a PHP script is equivalent to accessing it through a browser. cron.php is a file that is executed at a scheduled time. Note: If your command is not written correctly, you will receive an error message like "/bin/sh: /home/www.piaoyi.org/public_html/cron.php: Permission denied" or "No such file or directory" in your mailbox; if it is successfully executed, you will receive a code like "X-Powered-By: PHP/5.2.13 Content-type: text/html" in your mailbox. Regarding the time setting of crontab, the following are explained: The basic format of crontab is: This is the end of this article about how to use Cron Jobs to execute PHP on a scheduled basis under Cpanel. For more information about how to use Cron Jobs to execute PHP on a scheduled basis, please search previous articles on 123WORDPRESS.COM or continue browsing the following related articles. I hope you will continue to support 123WORDPRESS.COM in the future! |
<<: DIV common attributes collection
>>: Analysis of the situation where js determines and informs the support of CSS attributes (values)
This article example shares the specific code of ...
Table of contents Uncontrolled components Control...
Component Basics 1 Component Reuse Components are...
Table of contents environment: 1. Docker enables ...
Problem Description When filter attribute is used...
When to install If you use the protoc command and...
Routing configuration commands under Linux 1. Add...
Install antd-mobile Global import npm install ant...
When Docker creates a container, it uses the brid...
After the previous two chapters, do you have a ne...
1. First check whether the system has mysql insta...
When modifying Magento frequently, you may encount...
I searched online and found that many interviews ...
Worms replicate, as the name implies, by themselv...
This article uses an example to describe how to u...