In Python, is there an easy way to edit XML in place?
-
Suppose I want to edit a node in XML and edit one of its attributes. I want to be able to do a simple file diff to just see one row changed. Dumping the XML using prettyprint changes the whole XML structure.
-
Answer:
Does LXML's tree-modifying APIs suit your needs? http://codespeak.net/lxml/parsing.html#modifying-the-tree
Vaibhav Mallya at Quora Visit the source
Related Q & A:
- How To Find Easy Way To Speak English?Best solution by youtube.com
- Is there an easy way to learn Spanish?Best solution by Yahoo! Answers
- What is an easy way to make money?Best solution by Yahoo! Answers
- Is there an easy way to convert file types .aac,.m4a,.mov,.m4v,.mp4 to .wma?Best solution by Yahoo! Answers
- Is there a way to edit a line of tracking interference down recorded video tape on computer?Best solution by Yahoo! Answers
Just Added Q & A:
- How many active mobile subscribers are there in China?Best solution by Quora
- How to find the right vacation?Best solution by bookit.com
- How To Make Your Own Primer?Best solution by thekrazycouponlady.com
- How do you get the domain & range?Best solution by ChaCha
- How do you open pop up blockers?Best solution by Yahoo! Answers
For every problem there is a solution! Proved by Solucija.
-
Got an issue and looking for advice?
-
Ask Solucija to search every corner of the Web for help.
-
Get workable solutions and helpful tips in a moment.
Just ask Solucija about an issue you face and immediately get a list of ready solutions, answers and tips from other Internet users. We always provide the most suitable and complete answer to your question at the top, along with a few good alternatives below.