left menu permission control hidden memu to group.

Hi there,

left menu permission control ,how to hide memu item by roles?

I tried use CKxxx-group which fuction embeded with roles? but not sucess ,open page serveral times may sucess ,it seems it could not be able to get the userid whom logged ?do you hv any advise?

Solution

Hey Jack,

You can surround the menu items with an If condition that uses the CheckXRole function, would that help?  For example if the role is Admin, you can use CheckAdminRole(GetUserId())

Solution

Hi,Craig,


I tried ,it failed. do you know how to diagnose?


many thanks,

Jack

What do you mean by "it failed"?  Did you receive an error, did it not work because you could see it when you shouldn't, or did it not work because you couldn't see it when you should?  Can you provide a screenshot that shows what you did?

Hi Craig,

Thank you  ,let me check again .  It seems the cache issues.  I create 2 permission called P1(display menu1,2) , P2(display menu1) , I add my account to P2 ,  it works , I only see "menu1" , then I remove from the P2  , add my account to P1 . when I logoff and logon again , I still see the "menu1" , I can `t see the “menu2” , but  I change to another computer , it seems work fine .    will it be cached ? 

Many Thanks , 

Jack




Craig St.Jean wrote:

What do you mean by "it failed"?  Did you receive an error, did it not work because you could see it when you shouldn't, or did it not work because you couldn't see it when you should?  Can you provide a screenshot that shows what you did?



That's strange, the view should be generated server side so I suppose it could be some caching issue.  What browser are you using (and which version)?  Do you use any extensions?