class _forum_CrumbsPlugin__hierarchy in Crumbs, the Breadcrumbs suite 6.2
Same name and namespace in other branches
- 6 plugins/crumbs.forum.inc \_forum_CrumbsPlugin__hierarchy
Hierarchy
Expanded class hierarchy of _forum_CrumbsPlugin__hierarchy
File
- plugins/
crumbs.forum.inc, line 20
View source
class _forum_CrumbsPlugin__hierarchy {
/**
* Terms get their parent terms as breadcrumb parent.
* The method name matches the router path "taxonomy/term/%".
*/
function findParent__forum($path, $item) {
if (preg_match('#^forum/(\\d+)$#', $path, $m)) {
list(, $tid) = $m;
$q = db_query($sql = "SELECT parent FROM {term_hierarchy} WHERE tid = %d", $tid);
while ($row = db_fetch_object($q)) {
if ($row->parent) {
return 'forum/' . $row->parent;
}
}
return 'forum';
}
return '<front>';
}
}
Members
Name | Modifiers | Type | Description | Overrides |
---|---|---|---|---|
_forum_CrumbsPlugin__hierarchy:: |
function | Terms get their parent terms as breadcrumb parent. The method name matches the router path "taxonomy/term/%". |