/ Published in: CSS

We discovered that conditional comments don’t always work so well in SP2010. Instead, it is necessary to use a SP control. Below is the correct syntax.
Expand |
Embed | Plain Text
Copy this code and paste it in your HTML
Use <SharePoint:CSSRegistration Name="foo.css" ConditionalExpression="gte IE 7" runat="server" /> Instead of <!--[if gte IE 7]> <link rel="stylesheet" type="text/css" href="foo.css"/> <![endif]--> The former will generate the latter when the page is rendered.
Comments
