You are here

function apachesolr_get_enabled_facets in Apache Solr Search 6

Same name and namespace in other branches
  1. 5.2 apachesolr.module \apachesolr_get_enabled_facets()
  2. 6.2 apachesolr.module \apachesolr_get_enabled_facets()

Return the enabled facets from the specified block array.

Parameters

$module: The module (optional).

Return value

An array consisting of info for facets that have been enabled for the specified module, or all enabled facets.

5 calls to apachesolr_get_enabled_facets()
apachesolr_enabled_facets_form in ./apachesolr.admin.inc
Creates the form that allows the user to select which facets will be enabled.
apachesolr_og_block in contrib/apachesolr_og/apachesolr_og.module
Implementation of hook_block().
apachesolr_search_add_facet_params in ./apachesolr_search.module
apachesolr_search_block in ./apachesolr_search.module
Implementation of hook_block().
apachesolr_search_taxonomy_term_page in ./apachesolr.taxonomy.inc
Overrides taxonomy/term/X links

File

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

Code

function apachesolr_get_enabled_facets($module = NULL) {
  $enabled = variable_get('apachesolr_enabled_facets', array());
  if (isset($module)) {
    return isset($enabled[$module]) ? $enabled[$module] : array();
  }
  return $enabled;
}