(急-在线等)问一个两个子页面在同一个页面中问题

ywh005 2003-08-21 04:03:54
11.jsp部分代码:
<table width="98%" border="1" align="center" cellspacing="0" cellpadding="6" bordercolor="#6699CC">
<tr>
<td bgcolor="#eeeeee"><iframe src="1101.jsp" width="100%" height="150" frameborder="0" scrolling="auto"></iframe></td>
</tr>
<tr>
<td bgcolor="#eeeeee"><iframe src="1102.jsp" width="100%" height="300" frameborder="0" scrolling="auto"></iframe></td>
</tr>
</table>
其中1101.jsp中一个查询页面.1102.jsp是一个显示查询结果的页面
1101.jsp和1102.jsp都包含在11.jsp页面中.
但当我每次查询后,显示的结果却是1101.jsp页面中出现了查询结果(1101.jsp
页面中并没有1102代码,我用action="1102.jsp"导向了1102)即1101.jsp页面
的框架中的页面是1102.jsp页面,而下面(11.jsp)的1102.jsp页面没有反应.
我的想法是把结果显示在下面的那个1102.jsp页面中。

请问如何实现??????????
我想是我那个11.jsp写错了
...全文
33 6 打赏 收藏 转发到动态 举报
写回复
用AI写文章
6 条回复
切换为时间正序
请发表友善的回复…
发表回复
icecloud 2003-08-22
  • 打赏
  • 举报
回复
target="parent.window.102"

修改为 target="parent.102"
liad 2003-08-21
  • 打赏
  • 举报
回复
1101.jsp中的引用改为如下试试:
<form name="form1" method="post" action="1102.jsp" target="102" onSubmit="return checkform()">
ywh005 2003-08-21
  • 打赏
  • 举报
回复
我的11.jsp(主窗口)的代码如下:

<html>
<head>
<title></title>
</head>
<body bgcolor="#FFFFFF" text="#000000">
<table width="100%" border="0" cellspacing="0" cellpadding="0" align="center">
<tr>
<td width="85%">
<table border="0" cellspacing="0" cellpadding="0" class="p10">
<tr>
<td><img src="images/top_r2_c2.gif" width="6" height="26"></td>
<td bgcolor="#6699CC"><font color="#FFFFFF">整车发车情况登记</font></td>
<td><img src="images/top_r2_c4.gif" width="29" height="26"></td>
</tr>
</table>
</td>
<td width="15%" align="center"><img src="images/top_r2_c6.gif" width="25" height="26" onClick="showHelp()" style="cursor:hand" alt="帮助..."></td>
</tr>
</table>
<table width="100%" border="0" cellspacing="0" cellpadding="0" background="images/top_r3_c6.gif" align="center">
<tr>
<td><img src="../pub_images/top_r3_c2.gif" width="6" height="14"></td>
<td align="right"><img src="images/top_r3_c7.gif" width="17" height="14"></td>
</tr>
</table>
<hr noshade color="#ffffff">
<table width="98%" border="1" align="center" cellspacing="0" cellpadding="6" bordercolor="#6699CC">
<tr>
<td bgcolor="#eeeeee"><iframe name="101" src="1101.jsp" width="100%" height="400" frameborder="0" scrolling="auto"></iframe></td>
</tr>

<tr>
<td bgcolor="#eeeeee"><iframe name="102" src="1102.jsp" width="100%" height="400" frameborder="0" scrolling="auto"></iframe></td>
</tr>
</table>

</body>
</html>

1101.jsp中的引用是:
<form name="form1" method="post" action="1102.jsp" target="parent.window.102" onSubmit="return checkform()">

它就打开一个新的窗口显示1102.jsp中显示结果,而不是在11.jsp中的1102.jsp中显示结果。

大家看看错在那里。是不是11.jsp中错了??????????
ywh005 2003-08-21
  • 打赏
  • 举报
回复
按上面方面 它会出现一个新的窗体打开1102.jsp,而不是在<iframe>中的1102.jsp显示
不知为何??????
conning333 2003-08-21
  • 打赏
  • 举报
回复
<iframe src="1102.jsp" width="100%" height="300" frameborder="0" name="102" scrolling="auto"></iframe>

把 1101.jsp 的 form 的target设置为 target="parent.window.102"
ywh005 2003-08-21
  • 打赏
  • 举报
回复
大家知道吗???

81,094

社区成员

发帖
与我相关
我的任务
社区描述
Java Web 开发
社区管理员
  • Web 开发社区
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧