/[drupal]/contributions/modules/admintools/cron.module
ViewVC logotype

Diff of /contributions/modules/admintools/cron.module

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph | View Patch Patch

revision 1.9, Mon Jun 15 13:54:23 2009 UTC revision 1.10, Mon Jun 15 14:16:19 2009 UTC
# Line 1  Line 1 
1  <?php  <?php
2  // $Id: cron.module,v 1.8 2009/06/15 11:18:03 denraf Exp $  // $Id: cron.module,v 1.9 2009/06/15 13:54:23 denraf Exp $
3    
4  /**  /**
5   * @file   * @file
# Line 62  function cron_menu() { Line 62  function cron_menu() {
62      'page callback' => 'drupal_get_form',      'page callback' => 'drupal_get_form',
63      'page arguments' => array('cron_settings_form'),      'page arguments' => array('cron_settings_form'),
64      'access arguments' => array('admin tools'),      'access arguments' => array('admin tools'),
65      'weight' => 2,      'weight' => 3,
66      'type' => MENU_LOCAL_TASK      'type' => MENU_LOCAL_TASK
67    );    );
68    return $items;    return $items;
# Line 70  function cron_menu() { Line 70  function cron_menu() {
70    
71  function cron_list_form() {  function cron_list_form() {
72    
   if (($end = variable_get('cron_interval_end', 0)) && ($start = variable_get('cron_interval_start', 0))) {  
     $form['interval'] = array(  
       '#value' => t('The cron of this site runs every '.format_interval($end - $start)),  
     );  
   }  
   
73    $header = array(    $header = array(
74      t('Site'),      t('Site'),
75      t('Cron key (Drupal 7)'),      t('Cron key (Drupal 7)'),
# Line 339  function cron_interval_validate($form, & Line 333  function cron_interval_validate($form, &
333      drupal_goto('admin/settings/tools/cron/settings');      drupal_goto('admin/settings/tools/cron/settings');
334    }    }
335  }  }
336    
337    /**
338     * Implementation of hook_help().
339     */
340    function cron_help($path, $arg) {
341    
342      switch ($path) {
343        case 'admin/settings/tools/cron':
344          if (($end = variable_get('cron_interval_end', 0)) && ($start = variable_get('cron_interval_start', 0))) {
345            return '<p>'. t('The cron of this site runs every '.format_interval($end - $start)) .'</p>';
346          }
347      }
348    }
349    
350  /**  /**
351   * Implementation of hook_theme().   * Implementation of hook_theme().

Legend:
Removed from v.1.9  
changed lines
  Added in v.1.10

  ViewVC Help
Powered by ViewVC 1.1.2