絶対URI:http://java.sun.com/jsp/jstl/coreは解決できません
JSPファイルをViewリソースとして使用して、Spring MVCを開発します。
example.jsp
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>Spring MVC web application
上記は単純なJSPページですが、次のjstlエラーが発生しますか?
SEVERE: Servlet.service() for servlet mvc-dispatcher threw exception org.apache.jasper.JasperException: 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 at org.apache.jasper.compiler.DefaultErrorHandler.jspError(DefaultErrorHandler.java:51) at org.apache.jasper.compiler.ErrorDispatcher.dispatch(ErrorDispatcher.java:409) at org.apache.jasper.compiler.ErrorDispatcher.jspError(ErrorDispatcher.java:116) //...
溶液
デフォルトでは、jstl jarはSpringフレームワークに含まれていません。 修正するには、次のようにjstl依存関係を宣言します。
pom.xml
jstl jstl 1.2