Tuesday, February 4, 2014

SharePoint Branding - Add CSS / Stylesheet to MasterPage And Layout Page

I just wanted to make this small note for myself:

Add stylesheet to MasterPage

Put the code within head tag

<link rel="stylesheet" runat="server" type="text/css" href="<%$SPUrl:~SiteCollection/Style Library/Branding/css/styles.css%>" />

In case of layout pages:


<asp:Content ContentPlaceholderID="PlaceHolderAdditionalPageHead" runat="server">
<link rel="stylesheet" runat="server" type="text/css" href="<%$SPUrl:~SiteCollection/Style Library/Branding/css/styles.css%>" />
</asp:Content>

No comments: