当前位置: 代码迷 >> Web前端 >> 获取iframe里变量或步骤
  详细解决方案

获取iframe里变量或步骤

热度:30   发布时间:2012-09-07 10:38:15.0
获取iframe里变量或方法
ie&firefox 
      document.getElementById("frameId").contentWindow.varName;
      document.getElementById(" frameId ").contentWindow.functionName();
      document.getElementById(" frameId ").contentWindow.document.getElementById("someId");
      $("# frameId ").contents().find("# someId ");

  ie 
      document.frames(" frameId ").window.document.getElementById(" someId ");

  firefox 
      document.getElementById(" frameId ").contentDocument.getElementById(" someId ");

  相关解决方案