Using hook_form_alter on exposed view filters on Drupal 7 I'm having some trouble using hook_form_alter() with Views 3 and Drupal 7.  

I'm unable to add an if statement to uniquely identify a view; whatever I put in, the if statement is never found to be true. However, I can easily use the form_id using the following so I'm not sure where I am going wrong!

if ($form_id == 'views_exposed_form') {
}


How do I use hook_form_alter() to uniquely alter a single view of mine?
You can get access to the view object within hook_form_alter by accessing $form_state['view']. That allows you to identify a specific view:

function mymodule_form_alter(&amp;$form, &amp;$form_state, $form_id) {
    if ($form_id == 'views_exposed_form') {
        $view = $form_state['view'];
        if ($view-&gt;name == 'my_view_machine_name' &amp;&amp; $view-&gt;current_display == 'display_name') {
            // alter your exposed form here
        }
    }
}