Question

Beginner. I have created a custom template for a CQWP in the ItemStyle.xsl. One thing that I am not sure about is how I could associate a css file so that anytime this template style is used the results are rendered the same way. Is there a good approach to this, or can I even do it?

Was it helpful?

Solution

Reference the CSS file in the masterpage being used on the site.

Open your masterpage in SharePoint Designer and add this line in the header tag:

<SharePoint:CssRegistration runat="server" name="path to css file" after="corev4.css" />
Licensed under: CC-BY-SA with attribution
Not affiliated with sharepoint.stackexchange
scroll top