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, ...Differentiating between admin and content modules in SkinsDifferentiating between admin and content modules in Skins
Previous
 
Next
New Post
4/19/2011 9:04 AM
 
There has been a lot of discussion about the fact that the concept of an Admin page no longer exists since DNN5 as access to all pages (apart from super user pages) is now controlled in the same way by page security configuration. However, a very real distinction still exists between modules whose purpose is to manage content, and those that exist to configure the site. Yet apparently there is no way that a skin is able to distiguish between them.

Here's an example of why that can be problematic. Let's say you want your skin to add a standard border to all images element in the site content, but not to to display it for the graphics in the site admin pages, as the border in their case would be both pointless and ugly. Currently, the only way to achieve that is to apply styles on the basis of a list of all admin controls (or conversely all content controls) or to apply a skin / container other than the site default skin / container to all admin pages / modules (or all content pages / modules). This is time-consuming, error-prone and high-maintenance.

A better solution would be to enable a skin to differentiate between them simply by attaching a different CSS class on the module output. For example, the HTML is currently rendered within a containing div like:

<div class="DnnModule DnnModule-DNN_HTML DnnModule-1180">
</div>

Similarly, the tabs control is rendered within:

<div class="DnnModule DnnModule-Tabs DnnModule-1161">
</div>

Adding an extra class in the case of Admin modules would make differentiation simple; for example:

<div class="DnnModule DnnAdminModule DnnModule-Tabs DnnModule-1161">
</div>


Paul Taylor
Dotcom Software Solutions Ltd
DotNetNuke, ASP.NET and SQL Server Development
 
New Post
4/19/2011 11:37 AM
 

Hi Paul,

I'm not sure if you're asking a question or doing a suggestion, but maybe the 40Fingers Style Helper Skin Object could help you out.

Thanks to Ralph Williams who pointed me to this skin object (in an answer to a question I myself had).
 
New Post
4/19/2011 11:50 AM
 
Hi Gerard,

Thanks for pointing out this skin object, it looks interesting, and I'll check it out.

My post was a bit of both. The question is if anyone knows of an existing way of differentiating an admin module from a content one in a skin. If it's not possible, I have suggested how it could be implemented.


Paul Taylor
Dotcom Software Solutions Ltd
DotNetNuke, ASP.NET and SQL Server Development
 
New Post
4/19/2011 4:57 PM
 
dotcom wrote:

... The question is if anyone knows of an existing way of differentiating an admin module from a content one in a skin. ...

 It's not a perfect answer, but you might like to look at the techniques in this blog post.  I think they might allow you to get where you want to be fairly easily. http://www.thinkofdesign.com/blog/83/...


Best wishes,
- Richard
Agile Development Consultant, Practitioner, and Trainer
www.dynamisys.co.uk
 
New Post
4/20/2011 2:54 AM
 
Paul,

Wouldn't a separate skin for admin pages help?

The other solution would be as pointed out our skin object.
A. It allows you to either address a page on it's page  name, id or page order in the menu by adding a class to the body tag.
B. It can add a class for the roles a user is a member of (if the role has view rights on the page)
C. It can load an extra CSS file if a user is a member of a certain role (or not)

IfRole="Administrators" will match all users in the Administrators role.
IfRole="!Administrators" will match all users not in the Administrators role.
 
Previous
 
Next
HomeHomeUsing DNN Platf...Using DNN Platf...Skins, Themes, ...Skins, Themes, ...Differentiating between admin and content modules in SkinsDifferentiating between admin and content modules in Skins


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