Internet-Explorer – Special Use Conditions in IE

Today I encountered the use of IE conditional comments, which I have never seen before, which made me confused. This is how HTML started

< p>





...

I want to know how IE7 will handle this file. It seems that the document will eventually have two html tags, the first one is Undisclosed. Of course it won’t be parsed. But it does.
I decided to investigate.

In the IE7 browser mode of IE9, the html tag ended up being


It seems that it contains The attributes in the conditional comment’s html tag are being merged with the existing html tags. After further modification, if the attributes in the conditional html tag do not already exist in the first html tag, they will be added to the existing tag. For example:



The result is:


Here, the class attribute of the html tag included in the condition does not Any effect, because the unconditional html tag has defined a class attribute.Where the sizcache and sizset attributes come from is a complete mystery.

In any case, this observed behavior is not what I expected. The Microsoft documentation on conditional comments does not mention the use of such conditional comments, and Google searches have dried up.
The back of the page contains a style sheet that contains selectors that refer to IE7 and IE8 classes for use in IE 7 and 8. Override standard styles if they are presented incorrectly.

I’m just curious if anyone has seen the use of such conditional comments, or knows whether this mixed behavior is documented anywhere.

div>

This looks like a variant of technique developed by Paul Irish, but an incomplete one, which I suspect is not very predictable .

Today I encountered the use of IE conditional comments, which I have never seen before, which left me scratching my head. This is how HTML started





...

I I want to know how IE7 will handle this file. It seems that the document will eventually have two html tags, the first one is undisclosed. Of course it will not be parsed. But it does.
I decided to investigate.

< p>In the IE7 browser mode of IE9, the html tag is finally


It seems that the attributes in the html tags of the conditional comments are being merged with the existing html tags. After further modification, if the first html If the attributes in the conditional html tag do not exist in the tag, they will be added to the existing tag. For example:



WordPress database error: [Table 'yf99682.wp_s6mz6tyggq_comments' doesn't exist]
SELECT SQL_CALC_FOUND_ROWS wp_s6mz6tyggq_comments.comment_ID FROM wp_s6mz6tyggq_comments WHERE ( comment_approved = '1' ) AND comment_post_ID = 4285 ORDER BY wp_s6mz6tyggq_comments.comment_date_gmt ASC, wp_s6mz6tyggq_comments.comment_ID ASC

Leave a Comment

Your email address will not be published.