Setting Up Cron Jobs

There are two cron jobs you need to set up.

1. dap-cron.php: Should be set up to run once every hour. This script sends out all the scheduled bulk emails and processes the different type of “bulk” actions. Don’t worry about what those actions are. This just needs to run once every hour.

2. dap-emailorder.php: Should be set up to run once every 10 minutes. This is the cron script that processes all of your orders from your customers. DAP does almost all email processing. So, if you set this up to run once every 10 minutes, then every 10 minutes, it will log in to your billing email address (you can configure what this email id is within the admin control panel on the “Config” screen) and process the email notifications that you have received from Paypal, ClickBank or 1ShoppingCart (and its private labels).

There are two things you need to figure out:

a) The path to PHP on your host: They usually have this somewhere in your web site control panel. If not, just ask them or read their wiki.

For eg., on Dreamhost.com, it looks like this:
/usr/local/host/cgi-system/php5.cgi

b) You need your local path on your server to your root folder. For this, simply visit the following url:

http://www.Example.com/dap/getpath.php

This will spit out something like this:

/home/.xyz/yoursite/yoursite.com/dap

For the first cron, add the text “/dap-cron.php” to this path.

For the second cron, add the text “/dap-emailorder.php” to this path.

So, the full text to put in where it asks for the “Command to run” is this:

Cron 1:
/usr/local/host/cgi-system/php5.cgi<insert space>/home/.xyz/yoursite/yoursite.com/dap/dap-cron.php

Cron 2:
/usr/local/host/cgi-system/php5.cgi<insert space>/home/.xyz/yoursite/yoursite.com/dap/dap-emailorder.php

Where you see the text <insert space>, replace with an actual space (hitting the space bar).

Set Cron 1 to run hourly, and Cron 2 to run every 10 minutes.

That’s it!

1 comment so far ↓

#1 DAP Installation — DAP Documentation on 09.12.08 at 1:41 pm

[...] 5. Setting up the Cron job [...]

Leave a Comment