Skip to main content

You are not logged in. Your edit will be placed in a queue until it is peer reviewed.

We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.

Required fields*

8
  • 1
    Is the formatting important, or do you just want to extract all <data> tags and the lower tags? Commented Jul 14, 2016 at 14:56
  • thank you for helping me to make the format, Kusalananda Commented Jul 14, 2016 at 14:56
  • the format is important. Because I am passing the formatted data to a python script as arguement Commented Jul 14, 2016 at 14:56
  • 3
    It would be better if the Python script parsed the XML (using an XML parser) and extracted the bits it needed... Commented Jul 14, 2016 at 15:03
  • 1
    oh! I thought the format you mentioned was <data><name> there can be newlines after the data tag. Python is using xml.etree.ElementTree Commented Jul 14, 2016 at 15:18