The Drupal menu system is very smart about when it shows menus. It knows when a user has access to the menu, based on the roles the user has, and ultimately, the permissions the user has.
This is a great feature of Drupal. However, you still need to provide some form of navigation. Out of the box, Drupal provides a Navigation menu and both Primary and Secondary links menus. No matter which one you choose to use, you can enhance this navigation by making it easy for users to get to where they want to go - or even better, help them find the content they may be interested in.
In this video, I discuss the use to two different modules in particular. Dynamic Persistent Menu and the Me modules.
The information I provide in this video can apply to many other navigation modules. It's the Me module which is providing the magic to make your users happy with accessing their content. You find information about the specifics of Dynamic Persistent Menu and creating a block based navigation area for your site. The advantage to block based navigation (as opposed to html/template based) is that an admin user, with the right permissions, can control the menu to their heart's content.
If you have more suggestions about cool navigation and menu modules then please leave them in the comments below.
Modules referenced in this video
- Dynamic Persistent Menu [issues] - [usage]
- Me [issues] - [usage]
- Nice Menus [issues] - [usage]
Note: About the extra feature in Dynamic Persistent Menu. This is a link to the issue where I posted a patch that adds the checkbox feature of not showing submenus when the given url matches the menu which was selected.


I have played around with both Nice Menus and Dynamic Persistent Menu. They are both good. Your explanation of the workings of Dynamic Persistent Menu was quite informative. Thanks for the explanation of the "me" module as well. I just installed it after seeing this and it saved me a bit of work.
I use Menu Block ( http://drupal.org/project/menu_block ) in just about every installation these days as well as Menu Trails (http://drupal.org/project/menutrails).
Menu Attributes (http://drupal.org/project/menu_attributes) is very useful for advanced menu theming.
More modules for me to check out. Some I've not heard about. Boy, with so many modules out in the wild, it's like finding treasure every day!
Matt
Hi Matt,
First of all thank you for your helpfull website.
I followed your example and you can see an example at my homepage. However I got (Drupal) and a problem, once an user is logged the dynamic module don't work only in the homepage, but it does in all the other pages.
Do you have any idea?
I don't know what to do more?
Thanks Pietro
I use menu block and menu trails on many projects, great modules and they do save a TON of time. Menu trails gets things to behave as the user expects, and menu block just is plain awesome.
Do check them out if you haven't already!
You showed us how to add the nav menu to the info file, but what about the template? Surely you have to insert that block region into page.tpl.php or something no?
Great video as always!
Thanks Amy! You are correct. The $region, whatever name it is, needs to be added to the template - typically page.tpl.php.
Sorry for anyone watching the video who is not familiar with this. I was covering so many little things that I skipped over that part. For anyone wanting to know more about adding regions you can use these urls.
Thanks for such usefully video but I am a total beginner. Doesn't understand what the document is trying to say. I edited the page.tpl.php and doesn't know what to do next.
I was looking for a way to do just what this video describes. But, like you, I was totally confused as to how to define the regions.
A quick Google search quickly came up with this EXCELLENT resource:
http://mydrupalblog.lhmdesign.com/creating-custom-regions-drupal-6-themes
I'm either at the mature-beginner or barely-intermediate stage and this website page made the job super simple!
I managed to create two regions in about 10 minutes on my test server.
As soon as I get things configured to look a little prettier, I will be setting up a secondary menu using the information from this video on my own site, www.ovtoday.com. If you want to see the results, feel free to take a look after giving me a couple of days. I'm using the "Waffles" theme (which seems to be very popular) and defined two regions. I put one at the very top of the page for placing ads and the second just under the header for the secondary menus.
I hope the URL is helpful to anyone needing to create regions, but like me, are pretty uninitiated in the procedure.
I'd like to know how the "Get Video" image is placed on this site. I'd like to do something similar. How about a lesson on that?
Also, I want to take a moment to say how much help gotdrupal.com has been to me. I really appreciate the extremely high quality and volume of helpful videos on this site and have visited often for help. Thanks so much!
http://www.ovtoday.com/ - what is the name of the menu you use now, please?
And thanks very much for this video. It really help us newbies that you make this videos.
I'm going to use it on a site where I will link to a lot of cities showing each cities map like this one for Copenhagen http://www.tinemuller.dk/drupal/Copenhagen_map - so maybe this menu is not the best to use? What will you suggest me to use if not this?
http://da.wikipedia.org/wiki/Kommunalreformen_(2007)
Region Hovedstaden
29 cities
Region Sjælland
17 cities
Region Syddanmark
22 cities
Region Midtjylland
19 cities
Region Nordjylland
12 cities
And at last they will al be showed in ONE map where you can search for Radius like this http://www.tinemuller.dk/drupal/Copenhagen_map_radius.
Account menu module
This module provides the dynamic login/logout/my account links. The login link takes the user to login and brings them back to where they click the login link. The default behavior of going to the account page doesn't make any sense.
These links default in the "Account menu" so you can display them all by themselve. You can move them to the primary-links for your use case here at the admin/settings/accountmenu page, then use the admin/build/menu screen to arrange those links under the sub-menu.
You don't have any spam protection. How do you manage to avoid spam in these comments?
I switched to using Mollom about a year ago now. Very effective.!
Do you have something like spry menu?
Hi Matt,
Trying to get Dynamic Persistent Menu running as per your example as this is exactly my requirement. As a Drupal noobie I'm configuring modules but not coding so could you please provide instruction on how you modified page.tpl.php to make this work. (your instructions on how to modify the .info file were very clear).
Thanks! Andy J
I'd love to use these Dynamic persistent menus with the Acquia marina theme. I guess I need to know a lot more about themes before I can do this simply?
Andy J
We both love that them!
Drupal has been widely used with most people..
Drupal is one of the most popular content management systems used across the web. The Drupal content management system can be used to power many different types of websites including resource, portal, small business, educational and e-commerce websites.
drupal website designs || drupal website designer || drupal website development
I love your videos!
wonder what module are you using to get the neat Admin menus at the top?
I love your video! It's awesome. I'm going to apply it to my site.
This menu would be great for our project
I have spent the better part of 3 days trying to get this to work...
Our site is very early in build out...
so for page assignements, i am adding node/1 until we actually get the pages built... except for user/me installed 'me'
today i have even added the 'basic' theme as mentioned int he video -- still, no go...
in my info file i added with a text editor regions[navigation_menu] = Navigation Menu (BTW, how did you do this within drupal ? i see no way to do this sort of edit)
i added this to the basic page.tpl.php below header
<?php if ($navigation_menu): ?>
<div id="navigation-menu">
<?php print $navigation_menu; ?>
</div><!-- /#navigation_menu -->
<?php endif; ?>
in blocks 'basic' theme Dynamic persistent menu is set to Navigation Menu and the cfg for this is set to ---Primary links where i have several 'primary' links with many secondary links assigned to them
i have literally spent endless hours over 3 days on this and am completely befuddled --
I have very closely followed the video
any thoughts on what may be wrong?
How do we know calling this with field navigation_menu will actually work? the docs for this in the download suggest this can be displayed in any block - i have tried existing blocks - there is no display of this install in any existing block...
i have checked to see it is enabled, it is as is menu...
anyone have any ideas here?
thank you
well i got it to work... not sure how... :)
but now i am wondering how i set up the 'login' link on the sub menu in the primary links section menu item
how does this 'login' work? what makes the log in boxes display and then the login actually drop out of the menu?
many thanks...
I am discovering your website and there are lot of things very interesting....thank you very much to share all that.
I was wondering if you would mind to share your patch for the dynamic persistent menu you are talking about in this video?
Thank you and congratulations again for these videos.
Matt V.
Thank you for sharing the video! I learn a lot. classified |ad|tempurpedic mattress