Need extra help with your Joomla site? Consider paid Joomla support by the developer of Chameleon and MetaMod.
- Index
- » MetaMod
- » MetaMod General Support
- » Different Menu for Logged in users
Different Menu for Logged in users
Different Menu for Logged in users
I would like to show two different menus based on if the user is logged in or not. If a user is logged in, I would like to show a link to their PROFILE. If a user is logged out I would like to show a SIGN UP menu.
I followed the instructions provided but can't seem to get this to work. Can anyone help me please?
Re: Different Menu for Logged in users
Hi,
You've posted in the MetaMod forum, so I guess you've been using MetaMod for this. Things have gotten a bit easier for manipulating menu items if you actually use MetaTemplate instead. (free version is fine).
You want to achieve:
- the ability to show a menu item for logged-in users only (hiding the menu item for the SIGN UP), and for guests, hide the "Profile" menu item and show the SIGN UP menu item instead.
- these menu items are part of a larger menu.
correct?
HOW TO DO IT WITH METATEMPLATE
- download MetaTemplate (free) from http://www.metamodpro.com/metatemplate/download
- install it on your site
- set up your main (or whichever) menu with BOTH additional menu items: include the PROFILE menu item AND the SIGN UP menu item.
- Create a new rule in MetaTemplate. Call it something like "change menu items".
- in the main PHP box on the left, type the following:
if (MM_LOGGED_IN) return true;
- In the SUCCEED action on the right, in the "disable menus and menu items" box, select the SIGN UP menu item. This will disable that menu item for logged in users.
- In the FAIL action on the right, in the "disable menus and menu items" box, select the "PROFILE" menu item. This will disable that menu item for guests.
- save the rule. Finished.
Hope that helps!
Cheers,
Stephen
- Index
- » MetaMod
- » MetaMod General Support
- » Different Menu for Logged in users
Board Info
- Board Stats:
- Total Topics:
- 1689
- Total Polls:
- 6
- Total Posts:
- 5942
- Posts this week:
- 2
- User Info:
- Total Users:
- 7630
- Newest User:
- welch84998
- Members Online:
- 0
- Guests Online:
- 111
- Online:
- There are no members online
Forum Legend:
Topic
New
Locked
Sticky
Active
New/Active
New/Locked
New Sticky
Locked/Active
Active/Sticky
Sticky/Locked
Sticky/Active/Locked