I am migrating an old application from WebLogic to JBoss EAP 7.4. One of my JSP pages is giving me this error:
ServletException in '[mypage].jsp': value: javax.servlet.ServletException: java.lang.NoSuchFieldError: value
[...]
Caused by: java.lang.NoSuchFieldError: value
at org.apache.taglibs.standard.tag.el.core.OutTag.evaluateExpressions(OutTag.java:137)
[...]
The JSP starts like this:
<%@ taglib uri="/tags/struts-bean" prefix="bean" %>
<%@ taglib uri="/tags/struts-html" prefix="html" %>
<%@ taglib uri="/tags/jstl_core" prefix="jstlc" %>
And it uses the other tags like html and bean just fine before using jstlc. I am sure it correctly reaches the jstlc definition because, before failing, it executes:
<jstlc:forEach items="${myexpressionlist}" var="myvariable" > //working
But then, the first times it contains an expression like this:
<jstlc:out value="${myvariable.myfield}" /> //not working
The jsp crashes with the java.lang.NoSuchFieldError: value
error. It looks like it recognizes the "out" tag in the jstlc library but it doesn't recognize the "value" attribute inside it? The c.tld file contains the following lines:
<!DOCTYPE taglib
PUBLIC "-//Sun Microsystems, Inc.//DTD JSP Tag Library 1.2//EN"
"http://java.sun.com/dtd/web-jsptaglibrary_1_2.dtd">
<taglib>
<tlib-version>1.0</tlib-version>
<jsp-version>1.2</jsp-version>
<short-name>c</short-name>
<uri>http://java.sun.com/jstl/core</uri>
<display-name>JSTL core</display-name>
<description>JSTL 1.0 core library</description>
[......]
<tag>
<name>out</name>
<tag-class>org.apache.taglibs.standard.tag.el.core.OutTag</tag-class>
<body-content>JSP</body-content>
<description>
Like <%= ... >, but for expressions.
</description>
<attribute>
<name>value</name>
<required>true</required>
<rtexprvalue>false</rtexprvalue>
</attribute>
[...other attributes...]
</tag>
Lastly, the web.xml file contains the following lines:
<taglib>
<taglib-uri>/tags/jstl_core</taglib-uri>
<taglib-location>/WEB-INF/tld/c.tld</taglib-location>
</taglib>
What could I do to solve the NoSuchFieldError issue?