I have a Drupal site with an
Event content type. This content type has an
Event Categories taxonomy field on it, which, as you can guess, categorizes events.
When you navigate to the URL of a particular term of that taxonomy, you see a sort of calendar view of Events that are tagged with that term.
These term pages have aliases set up, so that instead of, for example,
taxonomy/term/436, you can see the taxonomy term page by navigating to, say,
This aliases are used to populate a menu which is used to navigate the calendar and see events only pertaining to one particular taxonomy term.
I am now tasked with integrating this sort of 'virtual calendar' (the menu and the taxonomy term pages) into an internal section of the site, which users have to log in to see.
We've created the internal section using the
context module, using the URL (and user roles) as a condition of the context. For instance, the page
/internal/calendar triggers the context to add blocks and other features that make up the internal part of the site (because the URL begins with
However the problem arises when I want to use the calendar menu to place the calendar inside the internal site. The menu links are set to
/calendar/special-events-- which, if an internal user navigated to, they would lose all the context that makes up the internal site. They will have navigated out of the internal site at that point.
I began to create a second menu, which was essentially the same as the Calendar menu, but all of the links began with
/internal/calendar/special-events, etc. Sure, it's duplication, but it's more or less manageable.
The problem arose when I tried to add a second alias to the taxonomy term page. I went to
admin/config/search/path and added an alias, so that the taxonomy term had two aliases:
/calendar/special-events /taxonomy/term/213 /internal/calendar/special-events /taxonomy/term/213
However, when I navigated to
/internal/calendar/special-events, the URL in the browser became
/calendar/special-events, which is the alias set on the taxonomy term page (the default, or primary, I guess you could call it). So because the URL doesn't contain
/internal, then the context didn't trigger, and I effectively navigated out of the internal site.
My question: How can I set up a second alias for a taxonomy term page so that it doesn't get re-written to the default alias?
I also tried setting up a URL pattern at
Internal calendar internal/calendar/[term:name] Taxonomy term Vocabulary is event_categories
But with the pattern, when I navigate to
internal/calendar/special-events, The URL remains as such, and the page renders the context items, but the content itself is rendered as a 404. So this does not appear to be a solution each.