0

How to print value in JSTL from java? (ofcourse I have declaring of JSTL lbrary i header) I have a one parameter String and i cant print it and i want to print it in JSTL on JSP page: It's doesn't work

String param = "lol";
<c:out="${param}/>
hetmanJIIIS
  • 96
  • 1
  • 9
  • 1
    What you have is not a parameter. It's a local variable. You can't print local variables using the JSTL. The whole point of the JSP EL and the JSTL is to avoid scriptlets completely. Don't use scriptlets. – JB Nizet Mar 02 '14 at 11:35
  • What JB Nizet said. More on subject: [How to avoid Java Code in JSP-Files?](http://stackoverflow.com/questions/3177733/how-to-avoid-java-code-in-jsp-files). – Pshemo Mar 02 '14 at 11:38
  • put it(param) into request or pagecontext scope amd then try to access. – Gautam Mar 03 '14 at 21:27

0 Answers0