You are here

function cleaner_settings_form in Cleaner 5

Same name and namespace in other branches
  1. 6 cleaner.module \cleaner_settings_form()
  2. 7 cleaner.module \cleaner_settings_form()

Define a form to control the settings.

1 string reference to 'cleaner_settings_form'
cleaner_menu in ./cleaner.module
Implementation of hook_menu().

File

./cleaner.module, line 54
Allows the admin to set a schedule for clearing caches and other stuff.

Code

function cleaner_settings_form() {

  // Pull in our form's style sheet.
  drupal_add_css(drupal_get_path('module', 'cleaner') . '/cleaner.css');
  $form = array();
  $ret = module_invoke_all('cleaner_settings');
  foreach ($ret as $module => $elements) {
    $mod = drupal_ucfirst($module);
    $form[$mod] = array(
      '#type' => 'fieldset',
      '#title' => $mod,
      '#collapsible' => TRUE,
      '#collapsed' => FALSE,
    );
    $form[$mod]['stuff'] = $elements;
  }
  return system_settings_form($form);
}