EXtjs 解决ie9 不支持extjs对象的 “createContextualFragment”属性或方法

if ((typeof Range !== "undefined") && !Range.prototype.createContextualFragment) {
         Range.prototype.createContextualFragment = function (html) {
             var frag = document.createDocumentFragment(),
            div = document.createElement("div");
             frag.appendChild(div);
             div.outerHTML = html;
             return frag;
         };
     }

posted @ 2012-02-01 18:46  sulin  阅读(710)  评论(0编辑  收藏  举报