How do I Display jsp source code in a jsp page
-
25-09-2019 - |
Question
I am writing documentation for a company widget i authored and would like to run it on our development site but i need to show some jsp source code in the page.
How do i stop code from being interpolated?
Solution
Replace <
by <
and >
by >
.
You can if necessary make it a bean property and use JSTL <c:out>
to display it. It by defaut does that job.
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow