When navigating to a JSP page that uses JSTL, I get an error:
Message org.apache.jasper.JasperException: Failed to load or instantiate TagLibraryValidator class: [org.apache.taglibs.standard.tlv.JstlCoreTLV]
Description The server encountered an unexpected condition that prevented it from fulfilling the request.
dependency
in pom.xml
:
<dependency>
<groupId>jstl</groupId>
<artifactId>jstl</artifactId>
<version>1.2</version>
</dependency>
(<groupId> javax.servlet </groupId>
also doesn't work)
JSP page:
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<meta name="viewport"
content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0">
<meta http-equiv="X-UA-Compatible" content="ie=edge">
<title>Error</title>
<style><%@ include file="/frontend/style/style.css"%></style>
</head>
<body>
<section class="error">
<div class="error__img"><img src="${pageContext.request.contextPath}/frontend/images/error.png" alt=""></div>
<p class='error__sorry'><c:out value="We are very sorry"/></p>
<form action="hotel" method="post" class="error__back">
<button type="submit" name="command" value="toMainPage">Back to main page</button>
</form>
</section>
</body>
</html>
Project structure, if important: