How To Setup Cronjobs cPanel
November 5, 2024 by Tuong Doan | Viewed: 2132

Introduction
Some features of website require cronjobs to carry out routine tasks.
Login cPanel
Firstly, go to your hosting address with port default 2083. Example: http://your_hosting_address:2083
Secondly, choose the Cron Jobs tab under the Advanced menu.
Select dropdown cronjobs and write command line and click Add New Cron Job, then it will appear in current cron jobs table.
Command Syntax
Case example: The cron link of module Product Stock Notifier for Opencart is http://mmosoc134.oc2x.mmosolution.com/index.php?route=mmos_cronjob/cronjob&sr_code=8375f0ef40
Add -wget
wget "http://mmosoc134.oc2x.mmosolution.com/index.php?route=module/mmos_product_notify/cronjob&secret_code=8375f0ef40"
Note: Your hosting will be heavy due to temporary files if you do not use below line. Finally, the best command should be bottom example:
Add --quiet --delete-after after wget
wget --quiet --delete-after "http://mmosoc134.oc2x.mmosolution.com/index.php?route=module/mmos_product_notify/cronjob&secret_code=8375f0ef40"