Win a copy of Learn Spring Security (video course) this week in the Spring forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Use of Class constants in EL expressions

 
Akshay Singhvi
Ranch Hand
Posts: 93
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello Ranchers,
Can we use constants declared in a class file in EL expressions for eg.
public class A {
public static final String a = "AB";
}

Now in the JSP, assume i have imported the class A then will this work
${A.a == "AB"}
 
Bear Bibeault
Author and ninkuma
Marshal
Pie
Posts: 64613
86
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
That is precisely the subject of this article.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic