You are here

public function CurrentSearchItem::getQueryString in Facet API 6.3

Same name and namespace in other branches
  1. 7.2 contrib/current_search/plugins/current_search/item.inc \CurrentSearchItem::getQueryString()
  2. 7 contrib/current_search/plugins/current_search/item.inc \CurrentSearchItem::getQueryString()

Helper function that returns a facet's query string.

Ensures that all active child values are deactivated along with the parent.

Parameters

array $item: The item as returned by FacetapiAdapter::getAllActiveItems().

FacetapiAdapter $adapter: The adapter object of the current search.

Return value

array An array containing the query string variables.

2 calls to CurrentSearchItem::getQueryString()
CurrentSearchGroup::execute in contrib/current_search/plugins/current_search/item_group.inc
Implements CurrentSearchItem::execute().
CurrentSearchItemActive::execute in contrib/current_search/plugins/current_search/item_active.inc
Implements CurrentSearchItem::execute().

File

contrib/current_search/plugins/current_search/item.inc, line 267
Current search plugin base class.

Class

CurrentSearchItem
Base class for current search item plugins.

Code

public function getQueryString(array $item, FacetapiAdapter $adapter) {
  return $adapter
    ->getProcessor($item['facets'][0])
    ->getQueryString($this
    ->getItemValues($item, $adapter), 1);
}