• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

struts-el vs EL

 
Tony Smith
Ranch Hand
Posts: 229
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am reading about struts-el seems really similar to EL. I looked online a little bit, seems like that is what people use before EL was invented. Is there any reason to use struts-el? Is there distinct difference between struts-el and EL?
 
Merrill Higginson
Ranch Hand
Posts: 4864
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
If your web application is a Servlet Version 2.4 application, You can use an EL expression anywhere in the JSP, including as an attribute of a Struts tag.

If your application is a Servlet 2.3 application, you must use the struts-el version of the Struts tags in order to substitute an EL expression as an attribute of a Struts tag. If you want to display the value of an EL expression anywhere else in your JSP, you must enclose it in a JSTL cut tag.

As far as the EL language itself, there is no difference. The syntax for an EL expression is the same regarless of which method you use.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic