<%@ taglib prefix="s" uri="/struts-tags" %>的问题
2014-10-20 10:55
447 查看
<%@ taglib prefix="s" uri="/struts-tags" %>的问题
2009-01-13 20:08lew1985 | 分类:网站使用 | 浏览34810次我购买了电子工业出版社陈天河老师的《Eclipse,Struts,Hibernate,Spring集成开发宝典》这本书,照着上面的实例操作时遇到几个问题,想请教您。举最后一章的东西说一下。 1.import com.opensymphony.xwork2.ActionSupport;这个问题是The import com.opensymphony cannot be resolved 2.return SUCCESS;问题是SUCCESS cannot be resolved 3.<%@ taglib prefix="s" uri="/struts-tags" %>问题是Cannot find the tag library descriptor for "/struts-tags" 在论坛上问了下,有人说放到 tomcat/lib 或者 tomcat/shared/lib 目录下面,我把文件复制放到 tomcat/lib 后,前2个问题没有了,但是第2个问题还存在。uri此时的路径是相对路径?如果是的,那是相对哪儿的。 顺便问下把struts的lib中的所有文件复制tomcat/lib 中,那以后就可以供多个项目使用?
我把struts2相关的文件放在WEB-INF/lib/下面了,但是import com.opensymphony.xwork2.ActionSupport;还是有问题The import com.opensymphony cannot be resolved 不知道还要怎么配置一下. <%@ taglib prefix="s" uri="/struts-tags" %>的问题Cannot find the tag library descriptor for "/struts-tags" 是在/struts-tags的/后面加个空格再删除空格后没有问题的,可能是输入法的问题,我是通过光盘上的文件直接copy的。
分享到:
2009-01-16 11:59提问者采纳
答题闯关,过关即送礼!快来参加~
<%@ taglib prefix="s" uri="/struts-tags"%>是引入struts2的标签库. 你只要把struts2相关的几个lib放在你工程的WEB-INF/lib/下面就可以了. 如:struts2-core-2.0.11.1.jar ognl-2.6.11.jar oro-2.0.8.jar freemarker-2.3.8.jar struts-core-1.3.5.jar 等等. 你的第二个问题是你的配置文件中没有找到.就是说你的 src 根目录下struts.xml文件中没有你指定的action 的 result 标记.如果result不指定name属性.默认就是 SUCCESS. 你的一,三的问题就是jar包没有找到
相关文章推荐
- <%@ taglib prefix="s" uri="/struts-tags" %>地址问题
- <%@ taglib prefix="s" uri="/struts-tags" %>地址问题
- <%@ taglib prefix="s" uri="/struts-tags"%>
- <%@ taglib prefix="s" uri="/struts-tags" %>的问题
- <%@ taglib prefix="s" uri="/struts-tags"%>
- <%@ taglib prefix="s" uri="/struts-tags"%>
- Struts的常用标签<%@ taglib prefix="s" uri="/struts-tags"%>
- 论 <%@taglib prefix="s" uri="/struts-tags" %> 的重要性
- 解决<%@taglib prefix="s" uri="/struts-tags"%>显示找不到
- struts2标签引用<%@ taglib prefix ="s" uri="/struts-tags"%>报错
- Struts的常用标签<%@ taglib prefix="s" uri="/struts-tags"%>
- <%@ taglib prefix="c" uri="http://java.sun.com/jstl/core" %>标签再使用时报错
- 引入不了<%@taglib uri="http://java.sun.com/jsp/jstl/functions" prefix="fn"%>标签库的问题
- <%@ taglib uri="http://jakarta.apache.org/taglibs/i18n" prefix="i18n" %>错误提示:找不到标签库
- <%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>会报错
- <%@ taglib prefix="r" tagdir="/WEB-INF/tags/r"%>
- <%@ taglib prefix="c" uri="http://java.sun.com/jstl/core" %>标签再使用时总是报错
- <%@ taglib prefix="c" uri="http://java.sun.com/jstl/core" %>标签再使用时报错
- <%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
- taglib prefix="s" uri="/struts-tags"