You are here

public function FacetapiAdapter::itemActive in Facet API 6.3

Same name and namespace in other branches
  1. 6 facetapi.adapter.inc \FacetapiAdapter::itemActive()
  2. 7.2 plugins/facetapi/adapter.inc \FacetapiAdapter::itemActive()
  3. 7 plugins/facetapi/adapter.inc \FacetapiAdapter::itemActive()

Tests whether a facet item is active by passing it's value.

Parameters

string $facet_name: The facet name.

string $value: The facet item's value.

Return value

Returns 1 if the item is active, 0 if it is inactive.

File

plugins/facetapi/adapter.inc, line 282
Adapter plugin and adapter related calsses.

Class

FacetapiAdapter
Abstract class extended by search backends that retrieves facet information from the database.

Code

public function itemActive($facet_name, $value) {
  return (int) isset($this->activeItems['facet'][$facet_name][$value]);
}