Indenting one long line
You enter
- Xml
- <?xml version="1.0"?><library><book id="1"><title>Dune</title><year>1965</year></book><book id="2"><title>Emma</title></book></library>
You get
- Status
- XML is well formed.
- Formatted
- <?xml version="1.0" encoding="UTF-8"?> <library> <book id="1"> <title>Dune</title> <year>1965</year> </book> <book id="2"> <title>Emma</title> </book> </library>
Each child element moves to its own line, two spaces deeper than its parent. Notice that the first line now also says encoding UTF-8, which the original did not state.
Run through the tool’s own code.