Win a copy of The Little Book of Impediments (e-book only) this week in the Agile and Other Processes forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

escape character in jsp page

 
Mohammad Miazi
Greenhorn
Posts: 10
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
In a jsp page how can I display?
<%=27 %>

I tried <\%=27 %\>, but it displays
<%=27 %\>

What is the escape character which tells container not to evalute?

- mmiazi
(SCWCD 1.4 in progress)
 
satishkumar janakiraman
Ranch Hand
Posts: 334
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi

Try this. I didnt try this. I think, it will work



If it works fine, post your reply in this forum

bye for now
sat
 
Mohammad Miazi
Greenhorn
Posts: 10
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Yes it works..
Thanks Sat.
Without using script, is it possible do the same thing using EL or JSTL?
I tried using JSTL:
<c ut value="<%= 27 %\>" />
Got error

Also tried:
<c ut value="<\%= 27%>" />
This time no error, but display <\% =27%> i.e. does not discard \
Tried other combinations placing \ in different places, but did not succeed.
--mmm
 
satishkumar janakiraman
Ranch Hand
Posts: 334
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi
Try this



bye for now
sat
 
James Turner
Ranch Hand
Posts: 194
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Maybe just: <\%=27 \%> ??

James.
 
Deb Sadhukhan
Ranch Hand
Posts: 67
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
&lt;%=27 %&gt; will do.

Anything like <\%=27 %\> because < & > are part of html syntax.
[ February 17, 2005: Message edited by: Deb Sadhukhan ]
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic