HTML Logo by World Wide Web Consortium (www.w3.org). Click to learn more about our commitment to accessibility and standards.

Moving forward with Composr

ocPortal has been relaunched as Composr CMS, which is now in beta. ocPortal 9 will be superseded by Composr 10.

Head over to compo.sr for our new site, and to our migration roadmap. Existing ocPortal member accounts have been mirrored.


Main Site Change Views with Permissions?

Login / Search

 [ Join | More ]
 Add topic 
Posted
Rating:
#107756 (In Topic #21000)
Avatar

Fan in training

Trying to understand how to show menu items and blocks per permissions

Hi there,

The main site page (not Welcome, but site) - I want the main-content menu items and center blocks to show or hide based on permissions. I'm having a hard time finding how to do this? In other words, a certain group would be able to view "Links, Galleries, Downloads, FAQs", whereas another group would view all 7 items. The first group would see a block in the center panel that shows the new topics in their specific forum (id 9), whereas the second group would see the General Forum Chat topics.

Hoping that's clear? Thanks for any help!

Cheers,
Stevie
Back to the top
 
Posted
Item has a rating of 5 (Liked by ARTStevie)  
Rating:
#107759
Avatar

Community saint

Edit the actual panels (pages) and you can use the if_in_group tag to surround the blocks in question.

Using the If In Group Tag in ocPortal | Arvixe Blog

If you want to do the same thing to the links in your blocks, edit the menus and there is a 'only show if has permission' setting for each of those and a way to hide them from guests completely. As long as you have the right permissions set of course, which can be done in the Permissions Tree Editor (where you can also set who can view Forums).

I don't think this answers your questions entirely, but hopefully it's a start :)
Back to the top
 
Posted
Rating:
#107760
Avatar

Fan in training

Thank you!
Is there any way to do something like this on each menu item in which it can automatically show or hide the item based on their permission to see the landing page? In other words, I want to hide "Contacts" for any group right now that doesn't have permission to see the Contacts page, and show it for those that do.

KingBast said

Edit the actual panels (pages) and you can use the if_in_group tag to surround the blocks in question.

Using the If In Group Tag in ocPortal | Arvixe Blog
Back to the top
 
Posted
Item has a rating of 5 (Liked by ARTStevie)  
Rating:
#107761
Avatar

Community saint

I think you would use the Permissions Tree Editor to do this also. My test install has no site zone, but that's where you will need to navigate to and then Catalogues -> Contacts. You can set who has access to view, etc...



And then, if you edit the menu (Structure -> Menu Management) containing the Contacts link, you can check the box that says 'Only show if has permission'.
Back to the top
 
Posted
Rating:
#107762
Avatar

Fan in training

Oh man, that makes total sense. Thank you for that!

KingBast said

I think you would use the Permissions Tree Editor to do this also. My test install has no site zone, but that's where you will need to navigate to and then Catalogues -> Contacts. You can set who has access to view, etc...



Back to the top
 
Posted
Rating:
#107763
Avatar

Community saint

You might also find it useful to check Global Privileges, as this allows for some extra fine tuning if needed. Glad I could help :)
Back to the top
 
1 guests and 0 members have just viewed this: None
Control functions:

Quick reply   Contract

Your name:
Your message: