diff --git a/project_solr.forms.inc b/project_solr.forms.inc
index eeafed8..ae8d4a1 100644
--- a/project_solr.forms.inc
+++ b/project_solr.forms.inc
@@ -30,7 +30,12 @@ function project_solr_browse_projects_form($form, &$form_state, $project_type) {
     }
   }
 
+  // Current query.
+  $env_id = apachesolr_default_environment();
+  $query = apachesolr_current_query($env_id);
+
   // Add the API compatibilty option, if applicable.
+  $api_vocab = FALSE;
   if (module_exists('project_release')) {
     $api_vocab = taxonomy_vocabulary_load(variable_get('project_release_api_vocabulary', ''));
     $vocabs[$api_vocab->machine_name] = TRUE;
@@ -41,14 +46,43 @@ function project_solr_browse_projects_form($form, &$form_state, $project_type) {
     $vocab = taxonomy_vocabulary_machine_name_load($vocab);
     $terms = taxonomy_get_tree($vocab->vid);
     $options = array('' => t(' - Any -'));
+
+    // Filter values take the form of facet_name:facet_value.
+    $facet_machine_name = 'im_taxonomy_vocabulary_' . $vocab->vid;
+    // Special facet machine name if this is the API vocab.
+    if ($api_vocab && ($api_vocab->vid == $vocab->vid) && $query) {
+      // Load facet definition.
+      $facet_definition = facetapi_facet_load('im_project_release_api_tids', $query->getSearcher());
+      $facet_alias = $facet_machine_name = $facet_definition['field alias'];
+    }
+    $default_value = '';
     foreach ($terms as $term) {
-      $options[$term->tid] = $term->name;
+      $options[$facet_machine_name . ':' . $term->tid] = $term->name;
+
+      // Determine any default values.
+      if ($query) {
+        foreach ($query->getFilters() as $filter) {
+          if (($filter['#value'] == $term->tid) && ($filter['#name'] == $facet_machine_name)) {
+            $default_value = $facet_machine_name . ':' . $term->tid;
+          }
+          // Check for api vocab.
+          elseif (($filter['#value'] == $term->tid) && ($filter['#name'] == 'im_project_release_api_tids') && $facet_alias) {
+            $default_value = $facet_alias . ':' . $term->tid;
+          }
+        }
+      }
     }
 
-    $form['term_vid_' . $vocab->vid] = array(
+    // Use the Apachesolr query string 'f'.
+    if (!isset($form['f'])) {
+      $form['f'] = array('#tree' => TRUE);
+    }
+
+    $form['f'][] = array(
       '#type' => 'select',
       '#title' => check_plain($vocab->name),
       '#options' => $options,
+      '#default_value' => $default_value,
     );
   }
 
