Forums Register Login

ELResolver get Current Tag Name

+Pie Number of slices to send: Send
I've written my own ELResolver to escape any HTML in the output and prevent XSS.
It works fine, but double escapes output in <c:out> tags.
The workaround is to add disable XML escaping in the c:out tag, but I would like to automatically stop escaping when the ELResolver is evaluating an expression inside a c:out's value attribute.
Is there a way of working out which tag I'm current inside?
I've looked at the JSP page context, but can't find anything suitable.
There's a hole in the bucket, dear Liza, dear Liza, a hole in the bucket, dear liza, a tiny ad:
a bit of art, as a gift, that will fit in a stocking
https://gardener-gift.com


reply
reply
This thread has been viewed 944 times.
Similar Threads
Struts Error Message
set "<div class='urg5'>High</div>" in JTSL
utf8_encode and htmlentities equivalent
JSTL c:if not working, but c:out is working
Using C:out in custome tag
More...

All times above are in ranch (not your local) time.
The current ranch time is
Mar 28, 2024 15:52:12.