Export (0) Print
Expand All

Element behaviors and HTCs are no longer supported

Support for element behaviors and HTML components (HTCs) has been removed in Internet Explorer 10 standards and quirks modes for improved interoperability and compliance with HTML5. This means elements previously bound to Element Behaviors or HTCs will be treated as generic elements, just like in other browsers. This change can impact pages written exclusively for Windows Internet Explorer or pages that use browser sniffing to alter their behavior in Internet Explorer.

Note  Most pages are unaffected by this change.

The following Document Object Model (DOM) properties are also affected by this change and are not supported in Internet Explorer 10 standards and quirks modes:

A page using Element Behaviors or HTCs worked as intended in Windows Internet Explorer 9, but no longer works in Internet Explorer 10.

If the page works correctly in other browsers, consider using feature detection to treat Internet Explorer 10 like other browsers. Otherwise, add the following meta tag near the top of the page to opt into Internet Explorer 9 behavior:


<meta http-equiv="X-UA-Compatible" content="IE=EmulateIE9">

The following example page uses Element Behaviors and might be impacted by this change:


<html xmlns:my>
  <?import namespace="my" implementation="my.htc">
  <my:element>
  This parses as an unknown element in Internet Explorer10 and other browsers.
  In older versions of Internet Explorer it binds to "my.htc".
  </my:element>
</html>


The page can be fixed quickly by opting into Internet Explorer 9 behavior, as shown here:


<html xmlns:my>
  <meta http-equiv="X-UA-Compatible" content="IE=EmulateIE9">
  <?import namespace="my" implementation="my.htc">
  <my:element>
  This parses as an unknown element in Internet Explorer 10 and other browsers.
  In older versions of Internet Explorer, it binds to "my.htc".
  </my:element>
</html>

The long-term solution is to revise the code to remove the dependency.

Related topics

Element Behaviors
IEBlog Post: HTML5 Parsing in IE10
How to Detect Features Instead of Browsers
Internet Explorer 10 Compatibility Cookbook

 

 

Show:
© 2014 Microsoft