You are here

function node_expire_admin_settings_validate in Node expire 8

Same name and namespace in other branches
  1. 7.2 node_expire.admin.inc \node_expire_admin_settings_validate()
  2. 7 node_expire.admin.inc \node_expire_admin_settings_validate()

Validation for the administrative settings form.

Parameters

object $form: An associative array containing the structure of the form.

object $form_state: A keyed array containing the current state of the form.

File

./node_expire.admin.inc, line 95
Administration page callbacks for the node_expire module.

Code

function node_expire_admin_settings_validate($form, &$form_state) {
  if ($form_state['values']['node_expire_date_entry_elements'] == 1 && $form_state['values']['node_expire_handle_content_expiry'] != 0 && !\Drupal::moduleHandler()
    ->moduleExists('date_popup')) {
    form_set_error('date_entry_elements', t('To use "Date popups" option Date module should be installed with Date Popup enabled.'));
  }

  // End of node_expire_admin_settings_validate().
}