Reputation: 7030
How we can add a CSS stylesheet (style.css) to an XSL file so that it works in Internet Explorer?
<head>
<title><xsl:value-of select="bom/header/title"/></title>
<link rel="stylesheet" type="text/css" href="/BOM-Download-portlet/css/styles.css" title="Style"/>
</head>
This is working in Firefox and other modern browsers, but not in IE
Upvotes: 0
Views: 565
Reputation: 478
IE does tend to cause a problem, so I've added exceptions in my .html files like so:
<!--[if lt IE 9]>
<script type="text/javascript" src="js/html5.js"></script>
<style type="text/css">.bg{ behavior: url(js/PIE.htc); }</style>
<![endif]-->
<!--[if lt IE 7]>
<div style=' clear: both; text-align:center; position: relative;'>
<a href="http://www.microsoft.com/windows/internet-explorer/default.aspx? ocid=ie6_countdown_bannercode">
<img src="http://www.theie6countdown.com/images/upgrade.jpg" border="0" alt="" /> </a>
</div>
<![endif]-->
The code as above acts as a script, detecting and changing the settings as required, also, it is in .html comments, so not picked up and attempted to be parsed while loading the page.
Hope this helps
Upvotes: 1