Search code examples
javajspglassfishhtmltidy

Feed rendered jsp pages through htmltidy


I have a Java project running on Glassfish that renders some ugly looking HTML. Its a side effect from using various internal and external JSP libraries. I would like to set up some sort of post-render filter that would feed the final HTML through HTMLTidy so that the source is nice and neat to aid debugging. Is this possible?

Is there a built in mechanism to perform some action after the server renders the JSPs into HTML? Can that action get the generated HTML as a string and manipulate it? Is there some easy built-in option to do this without extra coding?


Solution

  • JTidyFilter