没用过template这个标签,不过我看应该是你后面的路径有问题!
上面的文件
<template:put name='content' content='/content/indexContent.jsp'/>
<template:put name='footer' content='/content/footer.jsp' />
这当中的content我觉得应该将前面的/去掉!
上面的文件
<template:put name='content' content='/content/indexContent.jsp'/>
<template:put name='footer' content='/content/footer.jsp' />
这当中的content我觉得应该将前面的/去掉!
解决方案 »
- 一个关于spring的applicationcontext的问题
- 求救: struts2 validation框架验证问题
- 点击一个按钮,整个页面出现一个遮盖层,遮盖层弹出个页面框,框里有些form等
- 这个是做什么的Calendar.getInstance();
- 500错误不提示,怎么回事啊
- web service 客户端创建失败
- 怎样把连接数据库的错误信息显示到页面上
- 帮忙看看,用JSP链接mysql从数据库查数据时出现的问题????
- 从数据库读取后,select下拉单显示
- openfire4.3.2源码导入到eclipse中maven install时报错
- struts验证问题?
- 在mysql5的存储过程里,当有错误发生时,如何获得错误号是多少?
<%@ page contentType="text/html; charset=gb2312" %>
<%@ taglib uri='/WEB-INF/struts-template.tld' prefix='template' %>
<template:insert template='template/basicTemplate.jsp'>
<template:put name='title' content='XiaoXiao Forum' direct='true'/>
<template:put name='header' content='content/header.jsp' />
<template:put name='content' content='content/indexContent.jsp'/>
<template:put name='footer' content='content/footer.jsp' />
</template:insert>但是这句可以显示出来呢。(title)
<template:put name='title' content='XiaoXiao Forum' direct='true'/>
|--jsp
| |--xiao
| |--content
| |--template
|--WEB_INF
将第一个文件中content都改成下面试试:
../jsp/contentheader.jsp
都要改,看看!
<template:put name='header' content='/jsp/content/header.jsp' />
可以<template:put name='header' content='../jsp/content/header.jsp'/>
不行,
当前目录就是/jsp, 谁能告诉我为什么??