I’m using prototypejs templates on a JSP file.
But jsp file tries to parse #{} tags of prototypejs templates and hence it breaks.
How can I have jsp not parse them. I other words, how can I escape those tags?
Thanks.
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
Escape it with
\:var template = new Template('<a href="\#{href}" title="\#{title}">\#{name}</a>');Encode it as entity:
var template = new Template('<a href="#{href}" title="#{title}">#{name}</a>');Move it to JavaScript file.
Move it to Java code and write on JSP using EL
${}or JSTL<c:out />or Stuts<bean:write />