• JSON-XML conversions

JSON-XML conversions

XML ValidatorBuddy can convert XML to JSON and also from JSON to XML with a single click. To transform XML documents to JSON use the "Convert XML to JSON" command from the XML menu, for JSON to XML conversions use the "Convert JSON to XML" command from the JSON menu.
Convert the current document
Simply use the conversion commands from the XML or JSON menu to transform the active document to the other format. If the conversion was successfully the result is opened in a new document directly in the editor. The new document can be modified and saved afterwards.
Additional options for XML to JSON conversions
There are several options available to enhance the XML to JSON conversion process. With XML ValidatorBuddy you can apply a stylesheet to the XML before the XML is converted. This way you can transform the input or take only XML nodes you are interested in easily:
It is also possible to add prefixes to all attribute names coming from the XML. This allows to distinguish between element nodes and attributes also in the JSON output. In order to keep all namespace prefixes in JSON please check the "Keep namespace prefix" option. Otherwise all prefixes will be removed from the output.
Running conversions from the built-in File Explorer
XML ValidatorBuddy will convert all files selected in the File Explorer from XML to JSON. Regardless of the file extension the conversion process assumes that all selected files are XML documents and XML ValidatorBuddy tries to convert them to the JSON file format. After a document has been converted, a JSON well-formed check is applied to the output file to make sure that the generated text is readable JSON.
The converted JSON document gets the same file title with only the file extension replaced with .json. If there is already a file present with this name, the conversion is not executed and no document is written. In this case a message is added to the results window.
Use the "Convert JSON to XML" command from the JSON menu to convert any number of JSON documents to XML. The process is basically the same as the one from the XML to JSON conversion.
Copyright © 2015 by xml-buddy.com. All Rights Reserved.