I need to apply a CSS to a Sharepoint site (WSS3.0) based on the theme applied to a site. The CSS would be saved at root site in 'Document Library'. How do I apply the CSS programmatically on the page?
Thanks!
I need to apply a CSS to a Sharepoint site (WSS3.0) based on the theme applied to a site. The CSS would be saved at root site in 'Document Library'. How do I apply the CSS programmatically on the page?
Thanks!
Put in the page layout or master page. E.g.
<SharePointWebControls:CssRegistration ID="CssRegistrationMyCSS" name="<% $SPUrl:~sitecollection/Style Library/~language/Core Styles/myCSS.css %>" runat="server"/>
Programatically changing it requires you to modify the control on page load. Not sure how well it would work though.