function statcounter_cron in StatCounter 7.2
Implements hook_cron().
File
- ./
statcounter.module, line 183 - Drupal Module: Statcounter Adds the required Javascript to the bottom of all your Drupal pages to allow tracking by the Statcounter statistics service.
Code
function statcounter_cron() {
// Regenerate the statcounter.js every day.
if (REQUEST_TIME - variable_get('statcounter_last_cache', 0) >= 86400 && variable_get('statcounter_cache', 0)) {
_statcounter_cache('http://www.statcounter.com/counter/counter.js', TRUE);
variable_set('statcounter_last_cache', REQUEST_TIME);
}
}