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

HomeHomeArchived Discus...Archived Discus...Developing Under Previous Versions of .NETDeveloping Under Previous Versions of .NETASP.Net 2.0ASP.Net 2.0DNN Skin on a Popup Window!!DNN Skin on a Popup Window!!
Previous
 
Next
New Post
5/7/2007 7:50 AM
 

I am creating a DNN Module that, when a link is pressed, a popup window is created (MyPopup.aspx).  How do I apply the same skin/css to the popup window (MyPopup.aspx) that is appliced to the DNN portal??!!

 

Please help! 

 

V

 
New Post
5/7/2007 9:00 AM
 

The easiest way to do this would be to use Default.aspx in your popup but with a specific skin template. You can build the same functionality that is in MyPopup.aspx directly into that specific skin template. For example, if your skin is called MySkin and you have templates "Home.ascx" and "Portal.ascx", you would need to add another template called "Popup.ascx." You can customize Popup.ascx so it looks and does whatever MyPopup.aspx does. Then, you can add a hidden page on your portal and assign "MySkin - Popup" as the skin for the page. You can now call this page directly in the code you use to display your popup using Default.aspx?tabid=XXX where XXX is the ID of the hidden page.

Nik

 


Nik Kalyani
Co-founder
DotNetNuke Corporation
Blog | Twitter | FaceBook
 
New Post
5/7/2007 5:27 PM
 

Thats a great idea Nik (one which I will keep in mind) and thank you for the reply... but this solution probably relies too much on how the portal/tab are setups.  So if I wanted a few different Popups that are data-driven then it will start getting a bit messy. 

I was thinking that maybe the DotNetNuke framework keeps track of the .css files that are being used, ot there is a SPROC or an easy way I can get the .CSS path/fileName so I can simply link to it in the Popup.  If I can't have the whole skin in the Popup, I can atleast have the fonts and colors.

 

V

 

 

 
New Post
5/7/2007 7:02 PM
 

OK, Plan B, then...

When creating your popup link, use PortalSettings.ActiveTab.SkinSrc to obtain the skin template in use on the page. You may have to use SkinController.FormatSkinSrc() to translate this as it may begin with [G] or [L] to signify global (host) or local (portal) skin. You can pass this info to your aspx page.

Bear in mind that skins are not required to have a stylesheet named skin.css; the stylesheet could also have the same name as the template (i.e. PurpleHalo.ascx might use PurpleHalo.css). Knowing the skin location, you can test for the presence of these files before referencing them in your aspx page. Most of this logic is already present in ManageStylesheets() in default.aspx.vb and can be re-purposed.

Nik

 


Nik Kalyani
Co-founder
DotNetNuke Corporation
Blog | Twitter | FaceBook
 
New Post
5/7/2007 9:14 PM
 

Nik... I love you... in a manly sort of way.  

 
Previous
 
Next
HomeHomeArchived Discus...Archived Discus...Developing Under Previous Versions of .NETDeveloping Under Previous Versions of .NETASP.Net 2.0ASP.Net 2.0DNN Skin on a Popup Window!!DNN Skin on a Popup Window!!


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