Eclipse-绝对uri:无法在web.xml或与此应用程序一起部署的jar文件中解析http://java.sun.com/jsp/jstl/core [英] Eclipse -The absolute uri: http://java.sun.com/jsp/jstl/core cannot be resolved in either web.xml or the jar files deployed with this application

查看:615
本文介绍了Eclipse-绝对uri:无法在web.xml或与此应用程序一起部署的jar文件中解析http://java.sun.com/jsp/jstl/core的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我阅读了有关此错误的所有文章,但由于某种原因,它对我不起作用...

I read all the posts regarding this error but for some reason it does not work for me...

这是我的文件夹结构,

我收到标题中提到的错误,

I get the error as mentioned in my title,

if_tag.jsp的代码,

The code of the if_tag.jsp,

<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
<html>
<head>
<title><c:if> Tag Example</title>
</head>
<body>
<c:set var="salary" scope="session" value="${2000*2}"/>
<c:if test="${salary > 2000}">
   <p>My salary is: <c:out value="${salary}"/><p>
</c:if>
</body>
</html>

jstl库位于-

C:\tomcat\webapps\ROOT\WEB-INF\lib

推荐答案

如果要在Eclipse中的服务器上以动态Web项目的形式运行项目,则应通过右键单击>属性并选择部署程序集"来打开项目属性".在此处单击添加",选择"Java构建路径条目",然后选择"Maven依赖项",然后单击完成并应用".

if you are running the project as dynamic web project on a server within eclipse, then you should open the project properties by right click > properties and select "Deployment Assembly". There click "add", select "Java build path entries", and choose "maven dependencies" and then click Finish and Apply.

希望,它可能会起作用.它对我有用.

hope, it may work. it worked for me.

这篇关于Eclipse-绝对uri:无法在web.xml或与此应用程序一起部署的jar文件中解析http://java.sun.com/jsp/jstl/core的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆