Exception javax.el.ELException: The identifier [float] is not a valid Java identifier

tags: EL  Exception  struts-plus

This error only occurs with Tomcat7.X.

 

 

Use todayStruts 2 Extreme Form Validation Frameworkhttps://code.google.com/p/struts-plus/

 

Jsp code:

Floating point number range (1~10): <input name=float value="${param.float}" class="float-range-1-10"><br>
Access jsp report exception
javax.el.ELException: The identifier [float] is not a valid Java identifier as required by section 1.19 of the EL specification (Identifier ::= Java language identifier). This check can be disabled by setting the system property org.apache.el.parser.SKIP_IDENTIFIER_CHECK to true.
org.apache.el.parser.AstDotSuffix.setImage(AstDotSuffix.java:46)
org.apache.el.parser.ELParser.DotSuffix(ELParser.java:1067)
org.apache.el.parser.ELParser.ValueSuffix(ELParser.java:1033)
org.apache.el.parser.ELParser.Value(ELParser.java:978)
org.apache.el.parser.ELParser.Unary(ELParser.java:948)
org.apache.el.parser.ELParser.Multiplication(ELParser.java:712)
org.apache.el.parser.ELParser.Math(ELParser.java:632)
org.apache.el.parser.ELParser.Compare(ELParser.java:444)
org.apache.el.parser.ELParser.Equality(ELParser.java:338)
org.apache.el.parser.ELParser.And(ELParser.java:282)
org.apache.el.parser.ELParser.Or(ELParser.java:226)
org.apache.el.parser.ELParser.Choice(ELParser.java:183)
org.apache.el.parser.ELParser.Expression(ELParser.java:175)
org.apache.el.parser.ELParser.DynamicExpression(ELParser.java:147)
org.apache.el.parser.ELParser.CompositeExpression(ELParser.java:44)
org.apache.el.lang.ExpressionBuilder.createNodeInternal(ExpressionBuilder.java:116)
org.apache.el.lang.ExpressionBuilder.build(ExpressionBuilder.java:172)
org.apache.el.lang.ExpressionBuilder.createValueExpression(ExpressionBuilder.java:217)
org.apache.el.ExpressionFactoryImpl.createValueExpression(ExpressionFactoryImpl.java:67)
org.apache.jasper.runtime.PageContextImpl.proprietaryEvaluate(PageContextImpl.java:984)
org.apache.jsp.form_005fjs_jsp._jspService(form_005fjs_jsp.java:115)
org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)
javax.servlet.http.HttpServlet.service(HttpServlet.java:722)
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:419)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:391)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:334)
javax.servlet.http.HttpServlet.service(HttpServlet.java:722)
org.apache.struts2.dispatcher.FilterDispatcher.doFilter(FilterDispatcher.java:413)
 

 

Reason: ${param.float} float is the keyword of the el expression

Solution: ${param.float} to ${param["float"]}

 

 

Solution source:http://stackoverflow.com/questions/6233473/javax-el-elexception-the-identifier-return-is-not-a-valid-java-identifier

 

 

 

Intelligent Recommendation

Java identifier

Identifier: A sequence of characters used by Java to name elements such as packages, classes, methods, parameters, and variables. In short, name the class, interface, abstract class, interface impleme...

Identifier in java

What the identifier includes Class names, variable names, method names are all called identifiers Identifier naming rules Can only start with letters, _, $, and cannot contain special characters Canno...

Java: Identifier

Identifier 1. Keywords 2. All the components of java need names. Class names, variable names, and method names are all called identifiers. Identifier note...

fastDFS image upload and download

  java file js   Java file There are pictures with the fastDFS method and pictures without the fastDFS method. js is the same as others, fastDFS only configures some parameters, and then introduc...

More Recommendation

#python The Difference of the Tuple and List (List)

#python The Difference of the Tuple and List (List) Their writing and usage are very similar, silly, unclear. There are several statements: List is a variable object, tuple tuple is a non-variable obj...

UART(Universal Asynchronous Receiver/Transmitter)

UART driver implementation Operating system: bare metal IP version: dw_apb_uart Language: C language Machine: 32 -bit register UART base address UART interrupt number UART register structure include D...

SpringBoot idea how to display multiple startup class (Services column)

On this issue I also studied for a long time, ado, directly on the picture, follow the steps to can recall: Step one: Open to start the configuration edit configurations Click this button to click on ...

Getting started with struts2 (1)

Today is the first lesson of the school, at the end of the last semesterHibernateAfter we have not digested, we have contacted the second frame today.struts2Started this week with curiositystruts2。 St...

Copyright  DMCA © 2018-2026 - All Rights Reserved - www.programmersought.com  User Notice

Top