Skip to content

component jsontoxml

Raymond Meester edited this page Mar 7, 2023 · 2 revisions

Converts a JSON to XML.

Path

Path can be empty.

Options

Name Description Default Type
elementName Specifies the name of the XML tags representing array element e String
arrayName Specifies the name of the top-level XML element. For example, when converting [1, 2, 3], it will be output by default as 123. By setting this option or rootName, you can alter the name of element 'a' a String
rootName When converting any JSON object to XML, it specifies the name of the top-level element. If not set, it wil use o as a default value. If set to 'root', the JSON string { 'x': 'value1', 'y' : 'value2' } would turn into value1value2, otherwise the 'root' element would be named 'o' none String
namespaceLenient Whether to tolerate incomplete namespace prefixes false Boolean
typeHints Adds type hints to the resulting XML to aid conversion back to JSON. Used for unmarshalling (JSON to XML conversion). false Boolean
Clone this wiki locally