页面里有个 IFrame<iframe src="" id="ManagerPhraseMain_window" width="100%" height="50%" scrolling="auto" frameborder="0">
</iframe>有两个页签超链接,点击跳转到不同页面在这Iframe显示出来。<a href="javaScript:toManagePhrase1();" target="ManagerPhraseMain_window">function toManagePhrase1() {
 document.getElementById('ManagerPhraseMain_window').src = '<html:rewrite module="/WMS/ManagePhrase" action="ManagePhraseMain"/>'+'?hdnMethod=obtainPhraseList';
   }点击这个超连接,会弹出另外一个窗口,而且报 “缺少对象”.--------------------------------------------------------------------------------------我把超连接改为 <a onclick="javaScript:toManagePhrase1();" href="#" target="ManagerPhraseMain_window">Location.href = '<html:rewrite module="/WMS/ManagePhrase"action="ManagePhraseMain"/>'+'?hdnMethod=obtainPhraseList';则不会报错,但是整个页面都被跳转了,而不是只显示在 Iframe里面。

解决方案 »

  1.   

    <a href="javaScript:toManagePhrase1();" href="javascript:void(0);">function toManagePhrase1() {
    document.getElementById('ManagerPhraseMain_window').src = ' <html:rewrite module="/WMS/ManagePhrase" action="ManagePhraseMain"/>'+'?hdnMethod=obtainPhraseList';
      } 
      

  2.   


    页面会跳转,但是会把首页弹出来。跳转也没有跳转到Ifreame里面。而是把真个页面都刷了。
      

  3.   

    <html:rewrite module="/WMS/ManagePhrase" action="ManagePhraseMain"/>这个是生成url的吧?看看有没有其他的代码改变了窗体的url,像在iframe里面的页面有没有像parent.docuemnt.loaction="url"这样的语句
      

  4.   

    不是生成的,是写死的。这个是维护人家写的,不知道他那里做了什么设定。用 target参数,就会弹出一个登录页面。
      

  5.   

    用你新改后的,还有把<iframe src="" id="ManagerPhraseMain_window" width="100%" height="50%" scrolling="auto" frameborder="0">
    </iframe> 
    改成
    <iframe src="" name="ManagerPhraseMain_window" width="100%" height="50%" scrolling="auto" frameborder="0">
    </iframe>