Hello!

Your breadcrumbs feature is GREAT but I am trying to figure out how to configure it so that my site knows to have breadcrumbs throughout the site. Right now it only works for admin section but it does not appear in the main site (Primary links). Is there something I need to do to activate it? Right now it only shows "Home" on EVERY page...

let me know! thank you so much!

Comments

andregriffin’s picture

It seems your content is not hierarchical in more than one level. The breadcrumb only links back to home because all your primary sections have no parent page in themselves, thus only display a link to the global parent (home).

If you wish to display the current page in the breadcrumb trail, you need to replace the breadcrumb function in template.php in the Framework theme directory.
Find the function that looks like the following, and replace it with this: (note there is only two lines difference, the php function, and the comment explaining it)

/**
 * Return a themed breadcrumb trail.
 *
 * @param $breadcrumb
 *   An array containing the breadcrumb links.
 * @return a string containing the breadcrumb output.
 */
function phptemplate_breadcrumb($breadcrumb) {
  if (!empty($breadcrumb)) {
// uncomment the next line to enable current page in the breadcrumb trail
//  $breadcrumb[] = drupal_get_title();
    return '<div class="breadcrumb">'. implode(' » ', $breadcrumb) .'</div>';
  }
}

Uncomment (remove the "//") from the $breadcrumb[] = drupal_get_title(); line as it says, and that should fix your breadcrumb issue.

---Also---

I just remembered that this function was only really needed for Drupal 5.

The following module for Drupal 6 should do the same thing, and give you a few more options.
http://drupal.org/project/menu_breadcrumb

shali.nguyen’s picture

"It seems your content is not hierarchical in more than one level. The breadcrumb only links back to home because all your primary sections have no parent page in themselves, thus only display a link to the global parent (home)."

All of my sub pages are placed in menu to a parent page. I do have parent/child pages... not sure why this doesn't work. Do I need to do something extra other than placing them in parent/child order in the Menus to get this to work?

Thanks!

andregriffin’s picture

I'm not sure why this would be. Did you try either of the methods I explained?

Try installing this module.
http://drupal.org/project/menu_breadcrumb

If your sections are based on categories/taxonomy, try installing a module called Taxonomy Breadcrumb

shali.nguyen’s picture

got it to work! thanks so much!

andregriffin’s picture

Status: Active » Fixed
Anonymous’s picture

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for two weeks with no activity.