Ext 2.2 在IE9下报错 对象不支持“createContextualFragment”属性或方法
2013-09-14 16:20
288 查看
Ext 2.2 在IE9下报错 对象不支持“createContextualFragment”属性或方法
执行代码:
function openAlert() {
Ext.Msg.alert("提示消息", "提示内容");
}
有2种解决方案:
1.把Ext2.2 升级到 Ext3.4或者更高版本.
3.4下的效果
2.如果非要用Ext2.2 的话,需要在脚本中加入如下代码
if ((typeof Range !== "undefined") && !Range.prototype.createContextualFragment) {
Range.prototype.createContextualFragment = function (html) {
var frag = document.createDocumentFragment(),
div = document.createElement_x("div");
frag.appendChild(div);
div.outerHTML = html;
return frag;
};
}
执行代码:
function openAlert() {
Ext.Msg.alert("提示消息", "提示内容");
}
有2种解决方案:
1.把Ext2.2 升级到 Ext3.4或者更高版本.
3.4下的效果
2.如果非要用Ext2.2 的话,需要在脚本中加入如下代码
if ((typeof Range !== "undefined") && !Range.prototype.createContextualFragment) {
Range.prototype.createContextualFragment = function (html) {
var frag = document.createDocumentFragment(),
div = document.createElement_x("div");
frag.appendChild(div);
div.outerHTML = html;
return frag;
};
}
相关文章推荐
- Ext在IE9上报错:对象不支持“createContextualFragment”属性或方法
- Ext在IE9上报错:对象不支持“createContextualFragment”属性或方法
- EXTJS 2.2版本在IE9中会报错:对象不支持“createContextualFragment”属性或方法
- Ext在IE9上报错:对象不支持“createContextualFragment”属性或方法
- ext在ie9上报对象不支持“createContextualFragment”属性或方法
- EXT 错误 对象不支持“createContextualFragment”属性或方法
- 解决ie9不支持extjs3.3对象的“createContextualFragment”属性或方法
- ExtJs在IE9上报错:对象不支持“createContextualFragment”属性或方法(解决方案)
- EXtjs 解决ie9 不支持extjs对象的 “createContextualFragment”属性或方法
- 对象不支持“createContextualFragment”属性或方法
- Extjs: 对象不支持“createContextualFragment”属性或方法
- 对象不支持“createContextualFragment”属性或方法
- Extjs Microsoft JScript 运行时错误: 对象不支持“createContextualFragment”属性或方法
- 解决Ext在IE9上报错,createContextualFragment
- 音乐页在IE9下不能播放,提示“对象不支持xMusicPlayerPlay属性或方法”。
- 解决Ext在IE9上报错,createContextualFragment
- 对象不支持“handleError”属性或方法 ajaxfileupload.js
- 对象不支持此属性和方法
- 网页运行时提示对象不支持abigimage属性或方法
- 更新 JScript IntelliSense 时出错: D:\jqueryT\js\jquery-1.3.2.js: 对象不支持此属性或方法 @ 2139:1