zoukankan      html  css  js  c++  java
  • IE6下extjs 弹窗不加载内容(无法执行内部js)的解决方案

    
    
    //需要导入的文件,这里的路径需要些你自己的路径
       <link rel="stylesheet" type="text/css" href="ext/resources/css/ext-all.css" />
        <script type="text/javascript" src="ext/adapter/ext/ext-base.js"></script>
        <script type="text/javascript" src="ext/ext-all.js"></script>


    //
    用户信息 var winUi; function openIframeUi() { Ext.onReady(function() { var url = '<%=basePath%>user/update_user.jsp'; winUi = new Ext.Window({ width : width['ui_width'], height : height['ui_height'], param : window, title : '个人信息', closeAction : 'close', shadow : false, border:false, constrain : true, modal: true, //IE6 在IE6下不会自动加载iframe中的js,需要重新刷新一下才可以。这辈子我都不想接触IE6了,各种郁闷。 listeners:{ show:function(_window){ //刷新数据,如果不判断的话,firefox会报错。
                //尝试了很多方法 如_window.getEl().dom 然后获取iframe对象,再调用location.reload(),不知道为什么一直报错。更奇怪的是在ie6下有时候不reload()也能出来,有时候就不行。目前就这种最粗糙的方法来解决这个问题,原本不想给iframe定义name属性的。
                if(Ext.isIE6 || Ext.isIE7) {
                  document.frames('winUi').location.reload();
                } } },
    //autoLoad : {url : url, script : true} 设置script为true也不太好使 html : "<iframe name='winUi' width='100%' height='100%' src='" + url + "'/>" }); winUi.show(); }); }
  • 相关阅读:
    模块之datetime
    模块之time模块
    模块之相对路径导入
    模块之包跨模块导入
    模块
    迭代器
    leetcode234 回文链表(Easy,不简单)
    leetcode543 二叉树的直径(Easy 不简单)
    leetcode538 把二叉树转换为累加树(Easy,不简单)
    leetcode136 只出现一次的数字(Easy)
  • 原文地址:https://www.cnblogs.com/hzm112567/p/3207986.html
Copyright © 2011-2022 走看看