Products

Solutions

Resources

Partners

Community

Blog

About

QA

Ideas Test

New Community Website

Ordinarily, you'd be at the right spot, but we've recently launched a brand new community website... For the community, by the community.

Yay... Take Me to the Community!

Welcome to the DNN Community Forums, your preferred source of online community support for all things related to DNN.
In order to participate you must be a registered DNNizen

HomeHomeUsing DNN Platf...Using DNN Platf...Skins, Themes, ...Skins, Themes, ...Changing background based on user role?Changing background based on user role?
Previous
 
Next
New Post
8/4/2010 6:22 PM
 
The example I have on codeplex changes the background color of a div based on a role.
Check out the "Advanced" Example
 
New Post
8/5/2010 9:42 AM
 
Mmm... all the code I'm finding either doesn't work with DNN 5.04.02, or the code is deprecated.  Off to the manuals, I suppose.

All I want to do is say "If the user belongs to xxx role, then set the background to  yyy.jpg"

Thanks for the links however... I'm playing with code now, trying to see why things aren't quite correct.
 
New Post
8/5/2010 10:15 AM
 
SUCCESS. Here's what I did. I needed to change the background image, background color, and menu background colors. So what I did was this, in my skin.ascx file: <% If DotNetNuke.Security.PortalSecurity.IsInRole("Council") And Not DotNetNuke.Security.PortalSecurity.IsInRole("Administrators") Then%> <% End If%> ... works like a charm. It just overrides the CSS settings (since the html is the last thing rendered) if the user has a specific role.
 
New Post
8/5/2010 5:21 PM
 
Lol... it didn't show all my code.... evidently, I can't do styles in code...... anyway... I got it working..... I just put my new styles in between the IF and END IF.


 
Previous
 
Next
HomeHomeUsing DNN Platf...Using DNN Platf...Skins, Themes, ...Skins, Themes, ...Changing background based on user role?Changing background based on user role?


These Forums are dedicated to discussion of DNN Platform and Evoq Solutions.

For the benefit of the community and to protect the integrity of the ecosystem, please observe the following posting guidelines:

  1. No Advertising. This includes promotion of commercial and non-commercial products or services which are not directly related to DNN.
  2. No vendor trolling / poaching. If someone posts about a vendor issue, allow the vendor or other customers to respond. Any post that looks like trolling / poaching will be removed.
  3. Discussion or promotion of DNN Platform product releases under a different brand name are strictly prohibited.
  4. No Flaming or Trolling.
  5. No Profanity, Racism, or Prejudice.
  6. Site Moderators have the final word on approving / removing a thread or post or comment.
  7. English language posting only, please.
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out