Log in

View Full Version : IE8 and IE=EmulateIE7



molendijk
12-10-2009, 01:26 PM
Can anybody tell me why the following is problematic in IE8? The text cannot be selected, although a double click produces an alarm. So the text is not completely inaccessible. The problem is gone as soon as we get rid of the IE=EmulateIE7. Here's the page:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN"
"http://www.w3.org/TR/html4/strict.dtd">

<html >
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<meta http-equiv="Content-Style-Type" content="text/css">
<meta http-equiv="Content-Script-Type" content="text/javascript">
<meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7">


<title>Some title</title>

</head>

<body >

<div style="position:relative;top:300px;left:40%"><a ondblclick="alert('aaa')">Select this text</a></div>

</body>
</html>
===
Arie Molendijk.
===

jscheuer1
12-10-2009, 01:53 PM
It's a bug in IE 7 or, as MS devotees like to call it, a 'feature'. The event is not required for this to happen, the style alone is sufficient. The text is actually selectable. One may get it via the context menu or browser edit menu 'select all' option. One may also get it by a left-click drag of the mouse over the position where the text would have been if not positioned relatively.

It should be obvious then as to why, when emulating IE 7, that IE 8 would also exhibit this 'feature'.

molendijk
12-10-2009, 02:30 PM
Thanks!
Since I've IE8 installed (not to use actively, but to test scripts), I use the meta tag to see what 'would happen' in IE7. Well, this is one of those things that would happen.

Related point: so to test IE<7 in IE8, we would just have to put <!-- --> on top of the page. That would show us the behavior of IE<7 (?).
===
Arie.
===

jscheuer1
12-10-2009, 04:03 PM
Well, mostly. I have seen cases where the rendering wasn't the same as in IE 7. You can always install an IE 7 'standalone' (originally made for IE 6 users who didn't want to update but still wanted to be able to test in IE 7):

http://tredosoft.com/IE7_standalone

In fact, it is said that if you install that first, then their Multiple IE's:

http://tredosoft.com/Multiple_IE

That you can get a whole variety of IE's on your system.

I haven't tried this, though I do use their Multiple IE's for versions 6 and less - works great!.

molendijk
12-10-2009, 04:09 PM
Thanks!
Arie.