1

I am trying to increase the size of my views search filter form. The form id is views-exposed-form-blog--user-s-tab--page and am trying to use this in code I've used for my search block but its not working.

Here's my search block code -

function Themename_form_alter(&$form, &$form_state, $form_id) {
  if ($form_id == 'search_block_form') {
    $form['search_block_form']['#size'] = 26; 
  }
} 

Any ideas how I can make this work?

Thanks in advance

3

Perhaps you can get away with a simple CSS rule in your theme's stylesheet? Something like this:

#views-exposed-form-blog--user-s-tab--page input{width: 200px;} 

That width can be anything. In this example, it'd be 200pixels wide.

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.