Skip to content

Instantly share code, notes, and snippets.

@kae76
Forked from waako/gist:3835276
Created October 4, 2012 17:59
Show Gist options
  • Save kae76/3835304 to your computer and use it in GitHub Desktop.
Save kae76/3835304 to your computer and use it in GitHub Desktop.
<?php
/**
* Implements hook_form_alter().
*/
function sandbox_custom_form_alter(&$form, &$form_state, $form_id) {
kpr($form);
if ($form['#id'] == 'views-exposed-form-news-page') {
// $my_label = 'label name';
$my_label = $form['#info']['filter-type']['label'];
$form['type']['#options']['All'] = $my_label;
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment