Sometimes (or mostly on shared hosts) wo dont have ssh/shell acces to server to configure crontab. In this case we need to run crons manually or register for a paid cron-service or find an other solution. For my solution I need just one visitor a day to request a hidden img-tag. And its working; at least once a day Drupal runs cron.php.
- Create a block called something like "run cron manually"
- Activate your block; move to footer region etc
- Put following code and save as PHP-Filter (input format)
Code for "run cron manually with a footer block"
$now = time();
$last_run = variable_get("cron_last_run", 0);
$last_run = variable_get("cron_last_run", 0);
if( $now-$last_run > 86400 ){
variable_set("cron_last_run", $now);
return "<img src=\"/cron.php\" width=1 height=1 border=0>";
}