Skip retrieval of menu path on front page

dboulet - June 15, 2009 - 21:03
Project:Menu Breadcrumb
Version:6.x-1.x-dev
Component:Code
Category:bug report
Priority:normal
Assigned:Unassigned
Status:needs review
Description

I have a multilingual site, which has French as the default language. After installing this module, I noticed that my primary links were no longer visible on the English home page. The attached patch fixes the problem for me, it ensures that menu functions don't get called in menu_breadcrumb_init() if the current page is the front page. This patch has the added benefit of ensuring that the Home link on the front page always points to the front page, which would fix issues like this #278148: menu breadcrumb leads to wrong "home" breacrumb on startpage.

AttachmentSize
menu_breadcrumb_HEAD_front_page.patch1.34 KB

#1

niff - June 23, 2009 - 06:21

I had a similar problem with the primary menu, but on a Swedish site. Clicking any home link (link or logo) with the Swedish language active made the primary menu change language to English, but with the rest of the site in Swedish. This patch fixed that problem.

#2

dboulet - October 8, 2009 - 15:31
Title:Using menu functions in hook_init() confuses menu system» Skip retrieval of menu path on front page

Improved patch, rolled against latest HEAD.

AttachmentSize
menu_breadcrumb-HEAD_front_page.patch 1.37 KB

#3

xurizaemon - October 9, 2009 - 02:28

Looks like this patch will need re-rolling against #595282: Menu weights (unless that fix fixes this one).

#4

dboulet - October 9, 2009 - 03:15

If #595282: Menu weights gets committed, I can re-roll the last patch, but until then it still applies to the latest development snapshot, and is still valid. Since that issue is still under heavy development, I'll assume that there is still a possibility that this patch gets committed first.

#5

xurizaemon - October 9, 2009 - 03:59

You're right. I've been cleaning up a bunch of older issues today, and didn't spot that your patch was submitted quite recently. Sorry for missing that.

 
 

Drupal is a registered trademark of Dries Buytaert.