diff options
author | Gábor Hojtsy <gabor@hojtsy.hu> | 2007-10-25 08:24:43 +0000 |
---|---|---|
committer | Gábor Hojtsy <gabor@hojtsy.hu> | 2007-10-25 08:24:43 +0000 |
commit | 4e187261abc63432130bd3b5661b622ba095ffeb (patch) | |
tree | 9fd4b59b53cd8a3b1fb2c0e04b65c9f6eb998d71 /modules/taxonomy | |
parent | 9d5516644c5e6b607d01d6349a2890668a354efb (diff) | |
download | brdo-4e187261abc63432130bd3b5661b622ba095ffeb.tar.gz brdo-4e187261abc63432130bd3b5661b622ba095ffeb.tar.bz2 |
#177497 by chx and Desbeers: revive Drupal 5's menu_set_location() functionality by introducing menu_set_item() (for consistency in function naming), thus fixing a regression in the current development code. Also fixing some misuse of menu_set_location() by using drupal_set_breadcrumb() instead.
Diffstat (limited to 'modules/taxonomy')
-rw-r--r-- | modules/taxonomy/taxonomy.pages.inc | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/modules/taxonomy/taxonomy.pages.inc b/modules/taxonomy/taxonomy.pages.inc index 5ff9cff48..4f86441e9 100644 --- a/modules/taxonomy/taxonomy.pages.inc +++ b/modules/taxonomy/taxonomy.pages.inc @@ -32,13 +32,14 @@ function taxonomy_term_page($str_tids = '', $depth = 0, $op = 'page') { case 'page': // Build breadcrumb based on first hierarchy of first term: $current->tid = $tids[0]; - $breadcrumbs = array(array('path' => $_GET['q'], 'title' => $names[0])); + $breadcrumb = array(); while ($parents = taxonomy_get_parents($current->tid)) { $current = array_shift($parents); - $breadcrumbs[] = array('path' => 'taxonomy/term/'. $current->tid, 'title' => $current->name); + $breadcrumb[] = l($current->name, 'taxonomy/term/'. $current->tid); } - $breadcrumbs = array_reverse($breadcrumbs); - menu_set_location($breadcrumbs); + $breadcrumb[] = l(t('Home'), NULL); + $breadcrumb = array_reverse($breadcrumb); + drupal_set_breadcrumb($breadcrumb); $output = taxonomy_render_nodes(taxonomy_select_nodes($tids, $terms['operator'], $depth, TRUE)); drupal_add_feed(url('taxonomy/term/'. $str_tids .'/'. $depth .'/feed'), 'RSS - '. $title); |