OK, I’m new to this so bear with me. I have my website which is set up for Internet Explorer 9 and Safari, Chrome and Mozilla Firefox. But when I load my website on my computer with Internet Explorer 7 it displays this conditional div, but it still loads the content below it. Is there a way to stop it loading the content?
Here’s my source:
<!--[if lte IE 8]>
<div style=' clear: both; text-align:center; position: relative;'>
<a href="http://windows.microsoft.com/en-US/internet-explorer/downloads/ie-9/worldwide-languages"><img src="/protected-wp-content/images/internet-explorer-9-update.png" border="0" alt="" /></a>
</div>
<![endif]-->
<!--[if IE 9]>
<script type="text/javascript" src="js/html5.js"></script>
<link rel="stylesheet" href="css/ie.css" type="text/css" media="screen">
<![endif]-->
So, it appears that you want IE 8, and under users to see nothing but the update link?!?!
Leaving off whether that’s a good idea, here’s how to do it:
execCommand("Stop")halts the page load in IE. (Doesn’t work consistently in other browsers but that’s not an issue here. 😉