Nathaniel Flath Nathaniel Flath - 11 months ago 81
Java Question

How to escape HTML special characters in Java?

Is there a way to convert a string to a string that will display properly in a web document? For example, changing the string

"<Hello>"


To

"&lt;Hello&gt;"

Answer