function scs_form_alter in Simplenews Content Selection 7
Same name and namespace in other branches
- 6.2 scs.module \scs_form_alter()
- 6 scs.module \scs_form_alter()
Implements hook_form_alter()
Used to add an extra multistep operation to admin/content/node
File
- ./
scs.module, line 101 - Select Drupal content to create a newsletter
Code
function scs_form_alter(&$form, &$form_state, $form_id) {
if ($form_id == 'node_admin_content') {
if (isset($form_state['values']['operation']) && $form_state['values']['operation'] == 'scs_create') {
unset($form['filter']);
unset($form['admin']);
$form_state['scs'] = TRUE;
$form += _scs_get_metadata_form($form);
$form += scs_node_selection($form, $form_state);
$form['#theme'] = 'scs_sortable_table';
$form['#submit'][] = 'scs_node_selection_submit';
}
}
}