You are here

function apachesolr_default_environment in Apache Solr Search 7

Same name and namespace in other branches
  1. 8 apachesolr.module \apachesolr_default_environment()
  2. 6.3 apachesolr.module \apachesolr_default_environment()

Get or set the default environment ID for the current page.

49 calls to apachesolr_default_environment()
AbstractDrupalSolrOnlineWebTestCase::setUpSolr in tests/solr_index_and_search.test
apachesolr_bias_settings_page in ./apachesolr_search.admin.inc
Menu callback - Bias settings form.
apachesolr_config_file in ./apachesolr.admin.inc
Page callback to show one conf file.
apachesolr_config_files_overview in ./apachesolr.admin.inc
Page callback to show available conf files.
apachesolr_drush_solr_delete_index in drush/apachesolr.drush.inc
Selectively delete content from the apachesolr index.

... See full list

9 string references to 'apachesolr_default_environment'
apachesolr_search_menu_alter in ./apachesolr_search.module
apachesolr_search_page_list_pages in ./apachesolr_search.admin.inc
Listing of all the search pages
apachesolr_search_page_settings_form in ./apachesolr_search.admin.inc
Menu callback/form-builder for the form to create or edit a search page.
apachesolr_search_search_page_custom in ./apachesolr_search.module
Mimics apachesolr_search_search_page() but is used for custom search pages We prefer to keep them separate so we are not dependent from core search when someone tries to disable the core search
apachesolr_search_search_results in ./apachesolr_search.module
Executes search depending on the conditions given. See apachesolr_search.pages.inc for another use of this function

... See full list

File

./apachesolr.module, line 1136
Integration with the Apache Solr search application.

Code

function apachesolr_default_environment($env_id = NULL) {
  $default_env_id =& drupal_static(__FUNCTION__, NULL);
  if (isset($env_id)) {
    $default_env_id = $env_id;
  }
  if (empty($default_env_id)) {
    $default_env_id = variable_get('apachesolr_default_environment', 'solr');
  }
  return $default_env_id;
}