Search code examples
xmlcoldfusionpretty-print

Coldfusion - XML Pretty Print


There are a lot of ways to pretty print XML, but I have yet to find one using a ColdFusion function.

This is a common question, but again I want to do this within ColdFusion.


Solution

  • A quick search on http://cflib.org turned up xmlIndent().

    <pre>#xmlIndent(xmlString)#</pre>