You are here

function extra_body_classes_configuration in Extra body classes 7

Form constructor for the extra body classes configuration form.

1 string reference to 'extra_body_classes_configuration'
extra_body_classes_menu in ./extra_body_classes.module
Implements hook_menu().

File

./extra_body_classes.admin.inc, line 11
Main file for the Extra body classes module.

Code

function extra_body_classes_configuration($form, $form_state) {
  $form['extra_body_classes'] = array(
    '#type' => 'fieldset',
    '#title' => t('Extra body classes Settings'),
    '#tree' => TRUE,
    '#description' => t('Select the appropriate classes:'),
    '#collapsible' => FALSE,
    '#collapsed' => FALSE,
  );
  $form['extra_body_classes']['timestamp'] = array(
    '#type' => 'checkbox',
    '#title' => t('Add a date timestamp class'),
    '#description' => t('It allows user to add date timestamp class, for example, "20151007".'),
    '#default_value' => variable_get('extra_body_classes_timestamp', FALSE),
  );
  $form['extra_body_classes']['year'] = array(
    '#type' => 'checkbox',
    '#title' => t('Add a year class'),
    '#description' => t('This allow user to add current year as a class'),
    '#default_value' => variable_get('extra_body_classes_year', FALSE),
  );
  $form['extra_body_classes']['month'] = array(
    '#type' => 'checkbox',
    '#title' => t('Add a month class'),
    '#description' => t('This allow user to add current month as a class'),
    '#default_value' => variable_get('extra_body_classes_month', FALSE),
  );
  $form['extra_body_classes']['day'] = array(
    '#type' => 'checkbox',
    '#title' => t('Add a day class'),
    '#description' => t('This allow user to add current day as a class'),
    '#default_value' => variable_get('extra_body_classes_day', FALSE),
  );
  $form['extra_body_classes']['timezone'] = array(
    '#type' => 'checkbox',
    '#title' => t('Add a timezone class'),
    '#description' => t('This allow user to add current timezone as a class'),
    '#default_value' => variable_get('extra_body_classes_timezone', FALSE),
  );
  return system_settings_form($form);
}