if I have a string \"output\" that equals a url:
${output} = \"/testing/method/thing.do?foo=testing&bar=foo\"
in the jsp,
Try this:-
Granted, this will only escape special characters from XML.