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, ...Module.cssModule.css
Previous
 
Next
New Post
5/17/2012 9:25 AM
 

This may be better in localization or in module development but thought I would start here.


Is there a way to localize the module.css file per portal?  For example in the language localization you get something like resource-portal id -language or something like it each time a language is edited for a portal.

Is there the same kind of processing for module.css files? 


Dylan Barber http://www.braindice.com - Dotnetnuke development classes - skins and modules
 
New Post
5/17/2012 12:09 PM
 

Hello,

I don't know of one built into DNN, but, you could add it to the header during the page init. I actually have a small simple procedure I use for this sort of thing:

Public Shared Sub AddPageCSS(ByRef ModuleBase As DotNetNuke.Entities.Modules.PortalModuleBase, CssFileName As String)
ModuleBase.Page.Header.Controls.Add(New System.Web.UI.LiteralControl(String.Format("<link rel='stylesheet' type='text/css' href='{0}' />", ModuleBase.ResolveUrl(CssFileName))))

End Sub

Then you can just call it as needed and pass the css file you want along with the modulebase.

Mike

 
New Post
5/17/2012 12:25 PM
 

Mike that looks like it might work with some tweaking - i was also investigating the Continer.cs file in the library\ui\containers in the source - I think the way to do some dynamic loading would be to modify the processstylesheets method in that 


Mike looking over the code the method i mentioned looks to be obsolete - so there maybe a better place for that code to be more robust going forward


Dylan Barber http://www.braindice.com - Dotnetnuke development classes - skins and modules
 
Previous
 
Next
HomeHomeUsing DNN Platf...Using DNN Platf...Skins, Themes, ...Skins, Themes, ...Module.cssModule.css


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