Custom CSS file linked to MasterPage

…this post was published on 2014 October 19.

One of the principal changes made on Sharepoint 2013​ is masterpage.
If for SharePoint 2010 , you can changed .master file directly ( using for instance Sharepoint Designer ) in Sharepoint 2013 and Office 365 Enterprise versions  all changes are made in the .html page.
But if you try to add Style directly in that html page using this syntax directly in that html page using this syntax
<link rel=”stylesheet” type=”text/css” href=”path/custom.css”>
the changes will be not applied. In the .master page you will not found the reference to your custom css file
To   add in the .master page a refference to your css file , insert this code in the html master page
<!–SPM:<SharePoint:CssRegistration Name=”path/custom.css” runat=”server” after=”crev15.css” />–> 

This entry was posted in css, Sharepoint 2010, Sharepoint 2013. Bookmark the permalink.