Sunday, May 26, 2013

SetCronJob automatically corrects cron URL

Hello there,

I often receive message from users reporting their cronjobs are failing and they don't know why. I checked their cronjobs execution logs (hit the View logs icon) and found that their URLs just redirects to another "version" of themselves:
- Redirection from www to non-www version or vice versa e.g. from
http://example.com/cron.php
to
http://www.example.com/cron.php
- Redirection from http:// to https:// version or vice versa e.g. from
http://example.com/cron.php
to
https://example.com/cron.php
- Redirection to URL with trailing slash (after directory name) e.g. from
http://example.com/cron
to
http://example.com/cron/
(in this case, the index file e.g. index.php is the actual cron script).
- Some combination of redirections above.

For your convenience, SetCronJob will now automatically correct your cronjob URL (after first execution) so it's no longer a problem now.

Hope this helps.

Best regards,
Nguyen An Thuan.

No comments:

Post a Comment