You are here

function facetapi_map_assoc in Facet API 7.2

Same name and namespace in other branches
  1. 6.3 facetapi.module \facetapi_map_assoc()
  2. 7 facetapi.module \facetapi_map_assoc()

Wrapper around drupal_map_assoc() for a key in all items of an array.

Useful as an array_walk() callback.

Parameters

array &$array: The array being modified.

$name: The key of the array being modified, usually the name of a definition.

$key: The key in the array being passed to drupal_map_assoc().

2 string references to 'facetapi_map_assoc'
facetapi_get_facet_info in ./facetapi.module
Returns all defined facet definitions available to the searcher.
facetapi_get_searcher_info in ./facetapi.module
Returns all defined searcher definitions.

File

./facetapi.module, line 725
An abstracted facet API that can be used by various search backends.

Code

function facetapi_map_assoc(&$array, $name, $key) {
  $array[$key] = drupal_map_assoc($array[$key]);
}