By Steve on Tuesday, 25 February 2014
Posted in Technical Issues
Replies 5
Likes 0
Views 1.5K
Votes 0
I need to get EasySocial's cron job playing nicely with SH404SEF.

Here are my cron commands using WGET:
EasySocial Cron Job
/usr/bin/wget -O /dev/null "http://itchy-dog.co.uk/index.php?option=com_easysocial&cron=true&phrase=XXXXXX"; >/dev/null 2>&1
(Secret Key masked out)

EasyDiscuss Cron Job
/usr/bin/wget -O /dev/null "http://itchy-dog.co.uk/index.php?option=com_easydiscuss&task=cron"; >/dev/null 2>&1

EasyBlog Cron Job
/usr/bin/wget -O /dev/null "http://itchy-dog.co.uk/index.php?option=com_easyblog&task=cron"; >/dev/null 2>&1

If I set EasySocial to use Joomla's Router in SH404SEF, then everything is fine, however doing this means that SH404SEF no longer uses its custom 404 page and reverts to Joomla's default 404 page. Checking on SH404SEF this is the way it behaves - if a single component is set to Joomla Router then there is no custom 404 across the site.

If I set EasySocial to Default Handler in SH404SEF, then my custom 404 works, but the cron doesn't get the correct URL. If I copy and paste the URL into a browser, e.g. http://itchy-dog.co.uk/index.php?option=com_easysocial&cron=true&phrase=XXXXXX it actually goes to http://www.itchy-dog.co.uk/?cron=true&phrase=XXXXXX (due to SEF, I guess) so the cron task doesn't actually process.

If I copy and paste the cron URLs for EasyDiscuss and EasyBlog, then they appear to process correctly and I see messages confirming "Email batch process finished" and "0 blog posts fetched from Twitter", so there is only a problem with the EasySocial cron

Is there an alternative command to use in cron for EasySocial that would allow me to run the cron while also keeping SH404SEF's handler?
I'm guessing that a call to /usr/bin/php might work, but how would I format the command to run the php file?

Thanks,
Steve
Hello Steve,

Try adding &tmpl=component at the back of each URLs. If I recall correctly, SH404 will not rewrite URLs when it contains tmpl=component
·
Tuesday, 25 February 2014 20:16
·
0 Likes
·
0 Votes
·
0 Comments
·
Thanks Mark, that works directly in the browser, though I now seem to have another problem which I noticed as I went to test email notifications via the cron job.

The social bar drop down, search and Message buttons on a profile have all stopped working.
I know when I first installed, I had a Jquery conflict, and this appears to be the same. I switched SH404SEF back to Joomla router for SE wondering if I'd broken something there, but still the same.

The only other change this morning was updating Komento and EasyBlog to the latest versions.
I'm not sure quite what I might have done - a few hours ago this JQuery type behaviour wasn't happening as I was testing the messages and cron. Weird.
·
Tuesday, 25 February 2014 20:57
·
0 Likes
·
0 Votes
·
0 Comments
·
Some extra info - it appears to be the EasyBlog update.
Earlier I updated EB to 3.9.1274. I just reproduced this on my dev site, as soon as that goes on, the social bar, Message button etc stop working. I also just saw the update soon after to 3.9.1275, however that shows the same symtpoms.
I re-installed 3.9.15245 and the profile menu and MEssage button appear to work, but the search bar still doesn't. Went to send a test message and I get "Syntax Error: JSON parse unexpected character
·
Tuesday, 25 February 2014 21:33
·
0 Likes
·
0 Votes
·
0 Comments
·
OK, I've restored the site to prior installing the EasyBlog update and all is good again, SEF and Cron are working correctly, so thanks for that

I've got a copy of the site on a sub-domain for testing the Easyblog update, I'll check through the forums for any info on that, close this as resolved and start a new thread if needed for the Easyblog issues.

Thanks,
Steve
·
Tuesday, 25 February 2014 22:38
·
0 Likes
·
0 Votes
·
0 Comments
·
Thanks for updating Steve Glad that your issues are resolved now.
·
Tuesday, 25 February 2014 23:11
·
0 Likes
·
0 Votes
·
0 Comments
·
View Full Post