[support] Redirecting menu links

larry at garfieldtech.com larry at garfieldtech.com
Tue Aug 11 18:12:55 UTC 2009


This is a bit convoluted, so please bear with me. :-)

I have a site that is using Domain Access, and has 2 domains on it.

Each domain has a separate menu configured as its primary links menu. 
This menu is placed into a block in the sidebar.  So far so good.

However, we now need links in those menus.  On siteA, we need a link to 
/calendar, under which is a link to /calendar/concerts.  This is fine.

On siteB, we also need a link to /calendar, under which is a link to 
/calendar/concerts.

While those pages themselves function fine and pull in all of the 
appropriately domain-filtered data, the links themselves are problematic 
because of two issues:

1) If you put the same path in the menu system multiple times, Drupal 
frequently (although not always, just to keep things interesting) gets 
confused and will lose track of what the active menu path is.  That 
means expanded menus and breadcrumbs will be wrong.

2) In Drupal 5, the way around that was to use the url_redirect module 
to create a redirect, say, calendar-siteB, that directs to just 
/calendar, and put the redirect in the menu.  That worked wonderfully. 
However, Drupal 6 has a thoroughly annoying overly-sensitive permission 
check that breaks url_redirect:

http://drupal.org/node/190867
http://drupal.org/node/308263

So Drupal prevents us from taking that approach.

Anyone else have a suggestion for how to make those menu links work? :-)

--Larry Garfield


More information about the support mailing list