On one of my drupal 6 sites I have been noticing that Cron has not run. I checked my crontab and everything seemed right, so I went and attempted to manually run cron from the admin panel. It redirects me to node/36.

Now, after some investigation I have discovered what the problem is, but I would like to know why.

Alright, I have the event module loaded, and I have made custom content types for specific types of events.

I created primary links within the Garland theme that are basically pages that link to these custom event types in the event module. These pages are "taking over" or "hijacking" cron, and instead of allowing it to run, they redirect the page to their php results.

I have 3 of these link pages, and unless they are all edited out of their php code, they keep cron from running. Here is the code:

drupal_goto('event/' .  strftime('%Y/%m/%d') . '/month/area_ride');

Thanks

Comments

cjeanson’s picture

Is this something with cron or with the event module itself?

lsommerer’s picture

I just upgraded from 5.2 and I'm experiencing the same problem. Cron doesn't run, and everything seems to be setup correctly, and when I run cron manually I am redirected to a node that is not found. I was using the event module on the 5.2 site, but thought I might switch to date/calendar and so I have not installed the event module on the upgraded site. Never the less, the page I'm redirected to looks like it came from the events module: /event/2008/11/27/month/all/57

shs27’s picture

i get redirected to an event page, and don't know where to look to find the problem. i've uninstalled the event module, and wanted to use date/calendar. i've turned all of these modules off, uninstalled them, and still get the same "Page Not Found" problem when running cron.

lsommerer’s picture

It looks like this is a known issue with cron in Drupal 6.x. Here's the issue: http://drupal.org/node/102138

In my case, my problem turned out to be the same as the original poster. I had a piece of PHP code embedded in a page to construct a link to redirect to a certain view of the events module calendar. This worked fine in 5.2, but broke when I tried (rather unsuccessfully) to upgrade to 6.6.

The solution for me was to remove this code. I could not get the solution suggested in the above issue to work. Best of luck.

cmmurali78’s picture

in my case when i click the cron button it the page has been redirect to "page not found page ".

what can i do ?

help me out ..

thank in advance...

dvacher’s picture

Hello,

Before your redirection, add:

if($GLOBALS['user']->uid!=0)

It solve the problem for me.