JSTL not Working in Intellij 2016.1
Hi,
JSTL 1.2.1 , Servlet 3.0 , Tomcat 7 not working together in Intellij 2016.1
I have tested it on another IDE with the same code , structure and dependencies and it's works
but in Intellij 2016.1 not working (if the key is "mykey" the output ???mykey??? )
Code That i have used :
1- Resource Bundle :
ResourceBundle_ar.properties
ResourceBundle_en.properties
in package named test
2- web.xml header :
<?xml version="1.0" encoding="UTF-8"?>
<web-app xmlns="http://java.sun.com/xml/ns/javaee"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://java.sun.com/xml/ns/javaee
http://java.sun.com/xml/ns/javaee/web-app_3_0.xsd"
version="3.0">
</web-app>
3- Depandancies : (i tried with and without maven)
A- without maven:
javax.servlet.jsp.jstl-1.2.1.jar
javax.servlet.jsp.jstl-api-1.2.1.jar
B- with maven:(Pom File)
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>test</groupId>
<artifactId>test</artifactId>
<version>1.0.0</version>
<dependencies>
<dependency>
<groupId>javax.servlet.jsp.jstl</groupId>
<artifactId>javax.servlet.jsp.jstl-api</artifactId>
<version>1.2.1</version>
</dependency>
<dependency>
<groupId>org.glassfish.web</groupId>
<artifactId>javax.servlet.jsp.jstl</artifactId>
<version>1.2.1</version>
<exclusions>
<exclusion>
<artifactId>jstl-api</artifactId>
<groupId>javax.servlet.jsp.jstl</groupId>
</exclusion>
</exclusions>
</dependency></dependencies>
</project>
4- JSP Code:
<%@page contentType="text/html" pageEncoding="UTF-8"%>
<%@taglib uri="http://java.sun.com/jsp/jstl/fmt" prefix="fmt"%>
<%@taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
<%@ page isELIgnored ="false" %>
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>JSP Page</title>
</head>
<body>
<fmt:setBundle basename="test.ResourceBundle" var="langBundle" scope="session" />
<fmt:setLocale value="ar" scope="application" />
<fmt:message key="appmech" bundle="${langBundle}" />
</body>
</html>
Tomcat version : 7.0.69
Java Version : 1.7.80
IntelliJ IDEA Info
IntelliJ IDEA 2016.1.1
Build #IU-145.597, built on March 29, 2016
JRE: 1.8.0_60-b27 x86
JVM: Java HotSpot(TM) Server VM by Oracle Corporation
Where is the problem?
Thank you in advance
Please sign in to leave a comment.
Please continue the discussion here to avoid duplication: https://youtrack.jetbrains.com/issue/IDEA-159236#comment=27-1547528.
I am facing the issue when using jstl
Hello,
Please try suggestions mentioned here: https://stackoverflow.com/questions/4928271/how-to-install-jstl-the-absolute-uri-http-java-sun-com-jstl-core-cannot-be-r, https://www.fatalerrors.org/a/this-absolute-uri-cannot-be-resolved-in-either-web.xml-or-the-jar-files.html