Running a cron job for DownloadMail Plugin
8 posts by 5 authors in: Forums > CMS Builder: Plugins & Add-ons
Last Post: April 13, 2011 (RSS)
By Christopherb - July 30, 2010 - edited: July 30, 2010
The path is
/home/www/jackson/cmsAdmin/plugins/downloadMail/run.php
When the cron runs, we get the following error:
PHP Warning: require_once(../../lib/init.php): failed to open stream: No such file or directory in /home/www/jackson/cmsAdmin/plugins/downloadMail/run.php on line 4
PHP Fatal error: require_once(): Failed opening required '../../lib/init.php' (include_path='.:') in /home/www/jackson/cmsAdmin/plugins/downloadMail/run.php on line 4
From within the cmsAdmin the script runs fine...
Re: [Christopherb] Running a cron job for DownloadMail Plugin
By Jason - August 2, 2010
Even though it's producing an error, does it still download the emails?
If not, you can try to replace the path in run.php with the complete url to init.php, It would probably look something like this:
require_once("http://www.yourdomain.com/cmsAdmin/lib/init.php");
Hope this helps.
Jason Sauchuk - Project Manager
interactivetools.com
Hire me! Save time by getting our experts to help with your project.
http://www.interactivetools.com/consulting/
Re: [Jason] Running a cron job for DownloadMail Plugin
Got it to work with the full path.
Changed:
../../lib/init.php
to
/home/www/jackson/cmsAdmin/cmsAdmin/lib/init.php
Hope this helps someone else too...
Thanks,
Chris
Re: [Christopherb] Running a cron job for DownloadMail Plugin
By Perchpole - October 8, 2010
I'm new to this plugin and encountered a similar problem as Chris.
I could only get the cron job to run by prefixing the path with:
/usr/bin/php -q
The final command line looked something like this....
/usr/bin/php -q /my/path/to/plugins/downloadMail/run.php
Hope this helps too!
:0)
Perch
Re: [Perchpole] Running a cron job for DownloadMail Plugin
By Dave - October 8, 2010
interactivetools.com
Re: [Dave] Running a cron job for DownloadMail Plugin
/usr/bin/php -q /home/shaftsan/public_html/admin/plugins/downloadMail/run.php
I also updated the run.php to use the absolute URL and it still doesn't work.
Any insight would be awesome
Re: [Hybrid] Running a cron job for DownloadMail Plugin
By Dave - April 13, 2011
By default run.php won't work unless you disable the security check. We add this to a lot of our example pages so people aren't allowing code to run without knowing what it's for.
The solution is to edit run.php and remove the security check error. It looks like this:
die("Security Check - Edit run.php and remove this error before you use it.");
Just remove that line or put a comment # in front of it.
Let me know if that works for you.
interactivetools.com
Re: [Dave] Running a cron job for DownloadMail Plugin