我有一个main.jsp里面没有内容,内嵌了两个框架,代码如下:
<?xml version="1.0" encoding="UTF-8" ?>
<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<%@ taglib prefix="s" uri="/struts-tags"%>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<meta http-equiv="pragma" content="no-cache" />
<meta http-equiv="cache-control" content="no-cache" />
<title></title>
</head>
<frameset cols="220,*" frameborder="yes" border="0" framespacing="0">
<frame src="../../pages/frame/menu.jsp" name="leftFrame" id="leftFrame" scrolling="auto" />
<frame src="../../pages/frame/welcome.jsp" name="rightFrame" id="rightFrame" scrolling="auto" />
</frameset>
<noframes>
<body>
</body>
</noframes>
</html>我如果从login.jsp登陆页直接window.location.href="/pages/frame/main.jsp"则可以显示frame中两个页面,如果通过跳转后台,校验用户名密码后,使用struts配置文件返回此页(main.jsp),则为空白。
请问是什么问题?
路径我换成绝对路径也不行。
<?xml version="1.0" encoding="UTF-8" ?>
<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<%@ taglib prefix="s" uri="/struts-tags"%>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<meta http-equiv="pragma" content="no-cache" />
<meta http-equiv="cache-control" content="no-cache" />
<title></title>
</head>
<frameset cols="220,*" frameborder="yes" border="0" framespacing="0">
<frame src="../../pages/frame/menu.jsp" name="leftFrame" id="leftFrame" scrolling="auto" />
<frame src="../../pages/frame/welcome.jsp" name="rightFrame" id="rightFrame" scrolling="auto" />
</frameset>
<noframes>
<body>
</body>
</noframes>
</html>我如果从login.jsp登陆页直接window.location.href="/pages/frame/main.jsp"则可以显示frame中两个页面,如果通过跳转后台,校验用户名密码后,使用struts配置文件返回此页(main.jsp),则为空白。
请问是什么问题?
路径我换成绝对路径也不行。
解决方案 »
- 怎么在WAP网站中判断是手机浏览的还是电脑浏览的呀?
- 兑换诺言
- Hibernate 有点不明白的地方 请指教
- 很奇怪这样居然会抛出异常!!!!!千年一叹呀
- 这两种写法有什么区别吗?
- 数据库sql语句问题
- struts问题,错误提示Attribute maxLength invalid for tag text according to TLD
- JSP中调用JavaBean的问题
- 我遇到一个jsp数据库连接的问题(急!在线等!)
- 高手请指教,jsp和javascript和数据库联合动态生成树型结构,怎么实现呢????(在线等待给100分)
- spring mvc整合ajax
- 各位大侠,请赐小弟一招吧!两天了!
或是檢查server端有無錯誤訊息。
右键查看源文件,可以显示main.jsp页的源码内容,不过没有显示出两个框架内引入的jsp。
如果直接跳转到main.jsp,则直接显示的两个引入页的内容了。
<frame src="../../pages/frame/welcome.jsp" name="rightFrame" id="rightFrame" scrolling="auto" />
这样可能是因为<frame src="...."/> 不同于include 吧??? 我也不知道, 不过我是在 src=""用的一个请求action 即src="请求.action" 这样在加载main.jsp 的时候,就会自动触发,并把其返回的 视图 嵌套在 对应位置