Sign In  |  Register
 
 DotNetNuke Powered!
DotNetNuke Support Forums

Admin Only content for your DotNetNuke Skin

Rate this topic:

Please Register to post a reply.
Another benefit of registration is the ability to subscribe to and recieve notifications of new posts.

Page 2 of 2<< < 12
AuthorMessages
dschaening
Posts:15



07/31/2007 1:06 PM  

Ok, here is a little bump.

I would like to load a specific skin or menu image based on the role of the user...Any Ideas on that one?

John Mitchell
Posts:3040



07/31/2007 4:31 PM  

You could load a skin for a specific role by adding the code in this thread to the code in the following thread:

PortalAlias SmartSkin™ Switcher

robax
Posts:16



08/01/2007 5:48 PM  

Hi John,

Great threads here as always

I'm wondering what the proper syntax is to make this work for more than one role. My aging Sinclair BASIC skills have allowed me to make it work like this:

<% If DotNetNuke.Security.PortalSecurity.IsInRoles("Administrator") Or DotNetNuke.Security.PortalSecurity.IsInRoles("ThisRole") Or DotNetNuke.Security.PortalSecurity.IsInRoles("ThatRole") Then%>

But i don't know if that is in fact the correct or best way to do it. I always worry about adding too much additional processing to the site and for all I know, this sort of thing might be inefficient?

The basic scenario I'm trying to implement is: Don't show the content to unauthenticated users, also don't show it to stadard registered authenticated users (e.g. a forum user), but do show it to anyone who has a higher role than that.. someone who can submit and change content.

This is all about hiding that little help icon for everyone except people who have edit access to modules and such.

Any advice is much appreciated,

Rob

 

John Mitchell
Posts:3040



08/01/2007 6:03 PM  

Hi Rob, thanks for the Kudos.

How about only displaying it if the user has edit permission to the tab?

<%  If DotNetNuke.Security.Permissions.TabPermissionController.HasTabPermission("EDIT") Then %>
   
    Content for Tab Editors
        
<%  End If  %>
robax
Posts:16



08/01/2007 6:14 PM  
Hi John, Thanks for the prompt reply

I had a look at that in one of your other threads here, but I assumed that it only covers users with page edit rights.. and that's hardly anyone in my portal... and those couple that have it don't use it. Everyone manages their content at a much lower level. The main user has module edit rights and the one down from that has submitter rights for those modules that allow it, such as the repository.
Those are the people I want to show the help icons to, but I don't want to show it to forum users and unauthenticated persons.


Is there perhaps a "HasModulePermission("EDIT")" codey bit? That would get me most of the way there.
Rob
John Mitchell
Posts:3040



08/02/2007 9:16 AM  
The tab edit permission is the one that says a user is able to edit (add/delete/modify) any modules on the tab.

It sounds like you have assigned specific roles to specific modules so what you did in your first post is probably the best way to target those.
robax
Posts:16



08/02/2007 6:52 PM  
Ok cool, that's what I needed to know. Thanks very much for the information :D
Please Register to post a reply.
Another benefit of registration is the ability to subscribe to and recieve notifications of new posts.
Page 2 of 2<< < 12

Forums >DotNetNuke Support >Tips-And-Tricks > Admin Only content for your DotNetNuke Skin



ActiveForums 3.7
Visit our Store for great DotNetNuke Modules and Skins
DNNMasters Sitemap/Google Sitemap 3.0

Item codeSM3-01
Price$29.00
Product Information 
DotNetNuke CSS NavMenu 3.3 (Developers)

Item codeCSSNM33DEV
Base Price$149.00
Product Information 
Snapsis PageBlaster 3.3.2 for DotNetNuke - Professional Edition

AuthorJohn Mitchell
Base Price$79.00
Product Information