Status: New
Owner: ----
Labels: Type-Defect Priority-Medium

New issue 1282 by mikesamuel: HTML5 forward compatibility on IE
http://code.google.com/p/google-caja/issues/detail?id=1282

If we want standard but non HTML4 tags like canvas to work on IE, we might need to use the html5 shiv that Chad Killingsworth's pointed out : http://remysharp.com/html5-enabling-script


In Internet Explorer 8 and lower, simply issuing document.createElement("unknowntag") helps the browser to correctly recognize unknown tags and allows the developer to style
them through css. Without it IE chokes on unknown tags.

It has to be done once per unknown tag type :

var html5_elements =["abbr","article","aside","audio","canvas"];
var documentFragment = document.createDocumentFragment();
for (var i = 0; i < html5_elements_array.length; i++) {
 document.createElement(html5_elements_array[i]);
 documentFragment.createElement(html5_elements_array[i]);
}

Reply via email to