public static function FormHookHandler::hookFormAlter in Node expire 7.2
Implements hook_form_alter().
Adds expiration options to the node entry forms.
1 call to FormHookHandler::hookFormAlter()
- node_expire_form_alter in ./
node_expire.module - Implements hook_form_alter().
File
- src/
Module/ Hook/ FormHookHandler.php, line 138 - FormHookHandler class.
Class
- FormHookHandler
- FormHookHandler class.
Namespace
Drupal\node_expire\Module\HookCode
public static function hookFormAlter(&$form, &$form_state, $form_id) {
if (isset($form['type']) && (isset($form['type']['#value']) && is_string($form['type']['#value'])) && $form['type']['#value'] . '_node_form' == $form_id && ($ntypes = variable_get('node_expire_ntypes', array())) && isset($ntypes[$form['type']['#value']]) && ($ntype = $ntypes[$form['type']['#value']])) {
self::doFormAlter($ntype, $form, $form_state, $form_id);
}
}