//公司说要兼容 IE 6 ,我在IE6下 就这么句代码
    var ps_frame = {
        import: function () { alert("this is a test function."); }
    };
//说什么缺少标识符、数字什么鸟的
他娘的我把import改成任何其他的就好了,比如pmport
这解析的太刁了,还非得我取的鸟名字才行!让IE6去死吧!

解决方案 »

  1.   

    再一个问题:(没分数了,悲剧)
    又没人能翻译下:关于document.write的解释,
    You should not use the write or writeln methods on the current document after the document has finished loading unless you first call the open method, which clears the current document's window and erases all variables.
    Note  When document.write or document.writeln is used in an event handler, document.close should also be used.
    我在js文件里使用该函数导入其他js文件时,导入的js文件不是马上执行,而是等这个页面执行完才执行导入的js文件,why?
      

  2.   

    Ie6已被微软宣布死刑。
    http://www.ie6countdown.com/
    就是个折磨人的玩意儿,看到网页里那个地图,橙色的中国令人蛋疼。
      

  3.   


    我看到过Mozalla 有import的实现,不过只工作在signed scripts下。
    我大概帮你翻译一下。你不应该在完成加载的文档下用document.write或document.writeln,除非你先调用了open方法,这个open方法会清除当前文档窗口和擦出所有变量。
    注意 当document.write和document.writeln被用作事件处理时,document.close也应该用到。能力有限,有误的地方还望指正。
      

  4.   

    偶是老手的,今天被搞的头大一下没回过神。
    大家注意4楼阿,new question!!!
      

  5.   

    <script>
      var ps_frame = {
    "import": function () { alert("this is a test function."); }
      };
      alert(ps_frame);
      alert(ps_frame["import"]);
      // alert(ps_frame.import); 如有这行,无法执行
    </script>// JSON(www.json.org)的语法图有说明,一个对象{}的属性要用字符串来定义
      

  6.   

    6.0.2900.5512.xpsp_sp3_gdr.091208-2036
    我的IE版本号
      

  7.   


    那段英文主要意思就是不能在文档加载完成之后使用document.write和document.writeln。基本与你的问题没什么关联。
    而你所谓的导入js文件。请你详细描述下。
      

  8.   

    "import" 是 jscript5.0 为将来版本保留的关键字------jscript8(jscript.net) 中就使用 了 import