function crumbs_MultiPlugin_LegacyWrapper::findTitle in Crumbs, the Breadcrumbs suite 7.2
Find candidates for the parent path.
Parameters
string $path: The path that we want to find a parent for.
array $item: Item as returned from crumbs_get_router_item()
Return value
string[] Title candidates.
Overrides crumbs_MultiPlugin_FindTitleInterface::findTitle
File
- lib/
MultiPlugin/ LegacyWrapper.php, line 92
Class
- crumbs_MultiPlugin_LegacyWrapper
- A wrapper for legacy plugins with suffixed methods like findTitle__node_x().
Code
function findTitle($path, $item) {
$route = $item['route'];
if (isset($this->findTitleRouteMethods[$route])) {
$method = $this->findTitleRouteMethods[$route];
return $this->wrappedPlugin
->{$method}($path, $item);
}
elseif (method_exists($this->wrappedPlugin, 'findTitle')) {
return $this->wrappedPlugin
->findTitle($path, $item);
}
return array();
}