Skip to main content
removed 7 tag because this wasn't Drupal 7... also not really version specific
Link
Chaulky
  • 6.5k
  • 3
  • 43
  • 63
edited tags
Link
avpaderno
  • 97.9k
  • 15
  • 164
  • 284
Source Link
Chaulky
  • 6.5k
  • 3
  • 43
  • 63

Change the default selection for a Views 2 exposed filter

I have an exposed filter in my View that allows users to choose between two different content types. The default value for the exposed filter seems to be chosen by whichever content type comes first alphabetically. So, if I let users choose between "Band" and "Song" content types, the default is "Band". I want to change this default value to a different content type ("Song" in the example here). I can't find an option in the Views interface for this. Do I have to do this via hook_form_alter? If so, how exactly would I do that?