Setting Up Cron Jobs
(Note: You can get this setup as part of your free installation. But if you insist on doing it yourself, keep reading 🙂
There are two cron jobs (back-end, scheduled jobs) that you need to setup.
A) dap-cron.php (mandatory – once an hour)
This is the main one. It sends out broadcast emails, autoresponder emails, handles bulk member imports, affiliate commissions processing, clean up, etc. This one is mandatory.
B) dap-emailorder.php (optional – every 10 minutes)
This is the email order processing cron, used ONLY for 1ShoppingCart. Skip setting this cron up if you’re not using 1ShoppingCart or 1SiteAutomation.com.
Path to DAP
Visit the url below in a browser window (replace YourSite.com with your actual domain name):
This will show something like this in your browser:
This is your “Path to DAP” to your root folder.
To the end, add “/dap-cron.php”. So that makes your new “Path to DAP” to be:
This is your new “Path to DAP”. Make a note of this on a piece of paper, or in a notepad/text editor window.
Setting up the Cron jobs
This one is mandatory. Should be set up to run Once Every Hour. This hourly process is what sends out all the scheduled broadcast (bulk) emails and processes different types of “bulk actions” – like importing a large list of customers into DAP from an external system, for instance.
- Log in to your web host’s control panel (or cpanel)
- Look for the icon “Cron Jobs” in the “Advanced” section – usually towards the bottom of that page, and click on it.
- On the next window, in the “Common Settings” drop down, select “Once an hour (0 * * * *)“.
And in the “Command” field, enter this:/usr/bin/php
<insert space>above is just a note to you that means you must hit the spacebar and insert an actual space between the two pieces of text.
- Click on “Add New Cron Job”.
That’s it for this one.
Follow this step ONLY if you’re using 1ShoppingCart or any private label of 1SC – like 1SiteAutomation.com.
This cron job should be set up to run once every 10 minutes. This is the script that processes all of your recurring orders initiated by 1ShoppingCart or private label. 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 1ShoppingCart (and its private labels).
Running it sooner than once every 10 minutes – like say, once every minute or even once every 5 minutes – is resource intensive, and is not a good idea. Your web host may not not even allow it in the first place. But even if they do, it’s not recommended.
Follow steps A(1) through A(4) above. Only difference is in what you’re going to be entering in the “Command” field.
For this cron job, it is…
Only difference between the two cron jobs is in the name of script that is being run. For the hourly cron (A), it was dap-cron.php. For the 10-minute cron (B), it is dap-emailorder.php.
1. Where you see the text
<insert space>, replace with an actual space (hitting the space bar).
2. Cron Email Reports:
Your webhost control panel allows you to set an email address where it can send the cron output. So login to your Webhost Control Panel > Cron Jobs page, and remove your email address from that page (where it says “Please enter an email address where the cron output will be sent”).
3. To check if you have set up the cron job correctly, you can set DAP Admin -> Setup -> Config -> Log Level to “Log All Activity (During Troubleshooting)” . Then go to DAP Admin -> System -> Logs . Empty the logs by clicking on the “Empty Logs” link, and then revisit the screen and refresh the page, after say 10 minutes (to verify the running of dap-emailorder.php) or at the top of the hour (to verify the running of dap-cron.php).
4. To force run a cron (manually), click on this link:
(to run hourly cron)
(to run the email order cron that runs every 10 minutes)
Replace YourSite.com with the actual domain name of your web site.