Combined CSS tweek?

This forum is only for questions or discussions about working with the mojoPortal source code in Visual Studio, obtaining the source code from the repository, developing custom features, etc. If your question is not along these lines this is not the right forum. Please try to post your question in the appropriate forum.

Please do not post questions about design, CSS, or skinning here. Use the Help With Skins Forum for those questions.

This forum is for discussing mojoPortal development

This forum is only for questions or discussions about working with the mojoPortal source code in Visual Studio, obtaining the source code from the repository, developing custom features, etc. If your question is not along these lines this is not the right forum. Please try to post your question in the appropriate forum.

You can monitor commits to the repository from this page. We also recommend developers to subscribe to email notifications in the developer forum as occasionally important things are announced.

Before posting questions here you might want to review the developer documentation.

Do not post questions about design, CSS, or skinning here. Use the Help With Skins Forum for those questions.
This thread is closed to new posts. You must sign in to post in the forums.
8/2/2011 9:04:02 AM
Gravatar
Total Posts 76

Combined CSS tweek?

I have a module that uses alot of the SiteImages as css background images.

Was thinking that we could exclude images that start with "/Data/SiteImages/" from having the skin base url prepended to it when the css is combined, and save me from moving alot of these files into my skins...

 

CSSHandler.cs - Line 248:

if (!imgPath.StartsWith("http://") && !imgPath.StartsWith(@"/Data/SiteImages/"))

thoughts?

Warner

 

8/2/2011 9:59:52 AM
Gravatar
Total Posts 18439

Re: Combined CSS tweek?

Its already possible to include CSS files that are not in the skin folder. In the CSS the image urls always must be relative to the CSS file itself. I would suggest just put a CSS file in the /Data/SiteImages folder and include that in your style.config and use that file to setup whatever background images you are using from that folder. Then your urls in the CSS file will just be url('imagename.png'); I would not recommend using image urls with http because then if you have a page using SSL it will cause a browser warning about the image not using https.

Best,

Joe

You must sign in to post in the forums. This thread is closed to new posts.