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...Administration ...Administration ...Authentication and Customizing CSS within a page...Authentication and Customizing CSS within a page...
Previous
 
Next
New Post
11/20/2008 9:28 AM
 

Here's the deal.  I have a custom skin (modified CSS) for a specific page.  When a user logs in, that same page's style sheet needs to change so that certain things are visible only after authentication.

Pre Authentication: the top pane needs to be 400 px tall and the module needs to be invisible.

Post Authentication: the top pane needs to be 650 px tall and a module needs to be visible...

I already know how to make a module visible to registered users in the page's settings... I just need to know how to change the Page's Style Sheet before and after Authentication...

Is there a javascript function, an AJAX code, or anything that I can do to make it happen?  Any and all suggestions, codes, direction to other forum topics and other sites that have addressed this issue would be appreciated and rewarded.

 

Thanks for your time in advance.

 

-mb

 

 
New Post
11/26/2008 3:03 PM
 

Is it that I don't explain what I want clearly?  It seems like I don't get responses... ever.... I'm sorry I waste so much of your precious time in these forums. 

 
New Post
11/26/2008 6:24 PM
 


Before we tackle the solution, this really needs to be addressed:

I can understand your frustration at not getting a response (more accurately not quickly getting a response) from any of the thousands of registered DNN forum users.

I have to point out, however, that you've only previously initiated three threads since you joined a little over a month ago and you've had responses to two of the three threads.  You've therefore had a very good track record with responses (and that's not even counting this thread).  To say that you don't ever get a response and follow it with a snide comment is both unhelpful (to you) as well as untrue. 

This is a free product with a free forum for getting help (besides the hundreds of thousands of posts already made with valuable info in them).  You should be thankful for the 2/3 response ratio you've enjoyed in your very short time here.  I know I'm setting myself up to be flamed in response but this is the second thread you've posted a snide comment in and you've only posted in five threads so far.  Continue to post that way and no one will want to help (and you may even find yourself and your posts booted off the site, but then I'm neither a forums admin nor a rep for DNN so that's just my humble opinion).

Not that THAT has been said...

I think you've posted a great question whose solution can be helpful to a lot of users.  Here's one easy approach to this:


ALTER CSS BASED ON USER LOGIN STATUS
There are a number of ways to do this -- I'm going to outline the essentials of one potential solution.  Basically you simply swap one or more default CSS classes for variant version of the same classes.  Best of all, you use built-in DNN permissions and don't even have to modify your skin files.

In brief:

  1. Add a TEXT/HTML module to your target page and be sure to give it a descriptive title like "Modified CSS" (more on that, below).  Use MODULE SETTINGS->PERMISSIONS to set VIEW only for REGISTERED USERS (logged in users).  Also select the "NO PRINT" and "DO NOT DISPLAY CONTAINER" options while you're here.
     
  2. Use the moudle's EDIT TEXT, then select SOURCE.  Add STYLE tags and insert your modified versions of CSS default styles and/or classes between the STYLE tags.  CSS styles added at the module level override styles defined at the skin level.
     
  3. Click "UPDATE" and you're done!  Because the module has no visible content it will not be visible to non-admins and will take no space on the page.

You can do the same trick by inserting modified CSS class definitions using the PAGE's settings option "HEADER TAGS".  That would avoid adding a module but I much prefer using the module method because it is easy to forget that you've done something quirky in a page's HEADER TAGS.  With the module method you'll at least get a visual indicator that there is something extra on the page (an empty container with title "Modified CSS" when logged in as admin).

Pretty easy, eh?

Cheers!
-mamlin


esmamlin atxgeek.me
 
New Post
12/2/2008 9:35 AM
 

mamlin,

First, I would like to thank you for your response - first and foremost.  Your solution to this issue is beyond a shadow of a doubt, the most help I've gotten on this site with the exception to modifying an existing feedback module.... which was, yes, helpful, but not accurate.  I ended up going an entirely different route with it.

Secondly, please feel free to skip the next few sections if you get bored easily... and please don't take anything I say below as a personal retalliation nor as any sort of insult on your intelligence.

Thirdly, I realize it's free/free.  I get that part, but never have I gotten so little responses to my queries in other free/free forums with approximately the same amount of registered users.

A few things to be sure of when you are digging up my forum topics....


Help - Child Portals and other External Data Sources:
http://www.dotnetnuke.com/Community/Forums/tabid/795/forumid/108/threadid/261222/scope/posts/Default.aspx

there are only three responses in that forum post... all of which are mine...
The Post Date on the forum is 10/09... the next response from me... for clarification was on 11/03 (almost a full month later)
The final post, by me was on 11/12....


Click next... it's a completely different forum topic all together...

*************

Finally, as for response time as you mentioned - I'm actually doing this project for work.  It's not my decision, I would have gladly created my own site from scratch... but I walked into this project from a former employee who quit and couldn't handle the pressures of a deadline.

Coming from 9 weeks of unemployment and marching into this job with the intent of helping this company meet it's goal to go live by January 19th... which, normally - you would think would be an easy task, but in the national headquarters where NO ONE communicates with you on what each department wants to see on the site, it's a little frustrating....
(current site is http://www.emscorporate.com which will be replaced with the one I'm currently working on.)

I figured, if I could get the shell and filler content ready to go, I could just place the content where it was needed and be ready for the deadline, but - as you've noticed, when you get no responses to important issues, it gets frustrating because you are not able to do your job... and are getting ready for the next 9 weeks of unemployment.

 

Thanks again... if you stuck with me this long.

 
Previous
 
Next
HomeHomeUsing DNN Platf...Using DNN Platf...Administration ...Administration ...Authentication and Customizing CSS within a page...Authentication and Customizing CSS within a page...


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