You are here

public function FacetApiPrettyPathsCoderTaxonomy::decodePathSegmentValue in Facet API Pretty Paths 7

Same name and namespace in other branches
  1. 6.3 plugins/coders/facetapi_pretty_paths_coder_taxonomy.inc \FacetApiPrettyPathsCoderTaxonomy::decodePathSegmentValue()

Taxonomy special case: <alias>/<term-name>-<term-id>

Overrides FacetApiPrettyPathsCoderDefault::decodePathSegmentValue

See also

FacetApiPrettyPathsCoderDefault::decodePathSegmentValue()

File

plugins/coders/facetapi_pretty_paths_coder_taxonomy.inc, line 30
A taxonomy specific coder for pretty paths.

Class

FacetApiPrettyPathsCoderTaxonomy
Taxonomy specific implementation of FacetApiPrettyPathsCoder.

Code

public function decodePathSegmentValue(array $args) {
  $exploded = explode('-', $args['value']);
  $args['value'] = array_pop($exploded);
  return parent::decodePathSegmentValue($args);
}