https://briansnelson.com/index.php?title=Magento_:_Execute_Custom_Module_Cron_Manually&feed=atom&action=historyMagento : Execute Custom Module Cron Manually - Revision history2024-03-29T13:41:02ZRevision history for this page on the wikiMediaWiki 1.24.1https://briansnelson.com/index.php?title=Magento_:_Execute_Custom_Module_Cron_Manually&diff=1027&oldid=prevBrian: Created page with "==Magento1 - Execute Custom Module Cron Manually== let say we have cron setup on config.xml, like this <crontab> <jobs> <alertreminder_abdcart>..."2019-07-31T04:06:42Z<p>Created page with "==Magento1 - Execute Custom Module Cron Manually== let say we have cron setup on config.xml, like this <crontab> <jobs> <alertreminder_abdcart>..."</p>
<p><b>New page</b></p><div>==Magento1 - Execute Custom Module Cron Manually==<br />
<br />
let say we have cron setup on config.xml, like this<br />
<br />
<crontab><br />
<jobs> <br />
<alertreminder_abdcart><br />
<schedule><cron_expr>*/5 * * * *</cron_expr></schedule><br />
<run><model>alertreminder/cron::Abdcart</model></run><br />
</alertreminder_abdcart> <br />
</jobs><br />
</crontab><br />
<br />
and then a functions ready to execute<br />
<br />
class AN_Alertreminder_Model_Cron{ <br />
public function Abdcart(){<br />
//do something<br />
}<br />
}<br />
===Setup Manual Script===<br />
<br />
vim abdcart_cron.php<br />
<br />
Add the following<br />
<br />
<?php<br />
$model = Mage::getModel('alertreminder/cron');<br />
$model->Abdcart();<br />
?><br />
<br />
===Setup to run via your own cron:===<br />
<br />
crontab -e<br />
<br />
Add the following:<br />
<br />
* * * * * /path/magento/shell/abdcart_cron.php</div>Brian