function forum_CrumbsMonoPlugin_forumThread::findParent__node_x in Crumbs, the Breadcrumbs suite 7
Same name and namespace in other branches
- 7.2 plugins/crumbs.forum.inc \forum_CrumbsMonoPlugin_forumThread::findParent__node_x()
Forum nodes get their forum terms as breadcrumb parents. The method name matches the router path "node/%".
File
- plugins/
crumbs.forum.inc, line 95
Class
Code
function findParent__node_x($path, $item) {
$node = $item['map'][1];
// Load the node if it hasn't been loaded due to a missing wildcard loader.
$node = is_numeric($node) ? node_load($node) : $node;
if (!empty($node->forum_tid) && _forum_node_check_node_type($node)) {
return 'forum/' . $node->forum_tid;
}
}