Hi out there
I'm new to CMSMS (5 days).
I have been trying to find a exsample of how to create different menus depening on if the user is loged in or not.
Pages that are not accecible for users who are not logged in will not be shown.
Is this possible and please explain this in an understandable way......
regards
yggdrasil
Different menus for frontusers and logged in users
Re: Different menus for frontusers and logged in users
The answer is: Yes.
First of all you will need FrontEndUsers Module which you will find in the Development-Section of this website. Then you will be able to use the FrontEndUsers specific tags / snippets to do the following:
As you can see it is fairly simple to create stuff like that with CMS made simple.
Regards,
Nils
First of all you will need FrontEndUsers Module which you will find in the Development-Section of this website. Then you will be able to use the FrontEndUsers specific tags / snippets to do the following:
Code: Select all
<!--customContent: startif group=LoggedInUsers -->
{cms_module module="menumanager" template="LoggedInTemplate"}
<!--customContent: else -->
{cms_module module="menumanager" template="NotLoggedInTemplate"}
<!--customContent: endif -->
Regards,
Nils
Re: Different menus for frontusers and logged in users
Hello yggdrasil and welcome to CMSMS!
Your best help is usually searching the forum. I had the same problem as you before, found help from calguy1000:
In the manner described by calguy above you can have to totally different, or only partial different, menus depending on wheter the visitor is logged in or not.
Hope this is what you were looking for.
Oh, nils73 bet me to it. Two different solutions to the same problem.
Your best help is usually searching the forum. I had the same problem as you before, found help from calguy1000:
All you need are the two modules "Front End User" and "Cusom Content".calguy1000 wrote: hiding private pages is relatively simple, once you see it, but not easy to see.
There are a few ways to do this, but the steps illustrated below are the easiest
Step 1. Organize all of your private pages under one 'Section Header Parent'.
The 'Section Header Parent', should be marked as 'not shown in menu'
Step 2. Add syntax similar to the following in to an appropriate spot in your template
{if $customcontent_loggedin}
{cms_module module=menumanager template='whatever' startelement='' showrootsiblings='1'}
{/if}
In the manner described by calguy above you can have to totally different, or only partial different, menus depending on wheter the visitor is logged in or not.
Hope this is what you were looking for.
Oh, nils73 bet me to it. Two different solutions to the same problem.

Re: Different menus for frontusers and logged in users
Hello Nils and Zoorlat
I have allready tried What Nils described but this was not what I where going for.
How ever the solution described by Zoolat is interesting, but I can't get it to work.
This is what I have done for testing:
The following code is placed in the template (but for testing without the authentication):
{cms_module module=menumanager template='Elle' startelement=5.1 show_root_siblings=1}
How ever the content of the page in 5.1 does not appear in the menu. Why?
I belive that I, As you can see in the image attached, made the correct setting.
Regards
Yggdrasil
[gelöscht durch Administrator]
I have allready tried What Nils described but this was not what I where going for.
How ever the solution described by Zoolat is interesting, but I can't get it to work.
This is what I have done for testing:
The following code is placed in the template (but for testing without the authentication):
{cms_module module=menumanager template='Elle' startelement=5.1 show_root_siblings=1}
How ever the content of the page in 5.1 does not appear in the menu. Why?
I belive that I, As you can see in the image attached, made the correct setting.
Regards
Yggdrasil
[gelöscht durch Administrator]
Re: Different menus for frontusers and logged in users
Problem solved.....

It seemed to as if the selected template was not compatible with this option. By selecting another the problem was solved.
Regards and thanks


It seemed to as if the selected template was not compatible with this option. By selecting another the problem was solved.
Regards and thanks