<span class="Apple-style-span" style="font-family: arial, sans-serif; font-size: 13px; border-collapse: collapse; "><div>I want to say I just have to deal with some regular text input (the input file is as XML format) so I need to read all the nodes out and get what they are.</div>
<div><br></div>Thanks for your great help though. I should have made my point clearer. :)</span><br><br><div class="gmail_quote">On Thu, Apr 15, 2010 at 6:52 PM, Stefan Behnel <span dir="ltr"><<a href="mailto:stefan_ml@behnel.de">stefan_ml@behnel.de</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;"><div class="im">Jo Chan, 15.04.2010 10:52:<br>
</div><div class="im">> I just want to get the content from a XML.<br>
<br>
</div>That's not a very specific description of what you want to do. What's "the<br>
content"? The plain text content? Or do you care about the structure? And<br>
what parts of the structure?<br>
<div class="im"><br>
<br>
> I learn that there are two<br>
> modules in python handling XML.(SAX and DOM)  Er, I just want to know if<br>
> there is some open source tools for handling XML which is easier to use or<br>
> has more powerful function.<br>
<br>
</div>Try xml.etree.ElementTree, it's certainly much easier to use than the two<br>
above, and it's also in the stdlib. If you need more powerful features,<br>
take a look at lxml.etree, which is a (mostly) compatible external package.<br>
<div class="im"><br>
<br>
> By the way, besides<Diving into python>  is there any great book for<br>
> learning python?<br>
<br>
</div>That has been answered many times on this list. Check the archives, or look<br>
through the book references at <a href="http://wiki.python.org" target="_blank">http://wiki.python.org</a><br>
<div><div></div><div class="h5"><br>
Stefan<br>
<br>
--<br>
<a href="http://mail.python.org/mailman/listinfo/python-list" target="_blank">http://mail.python.org/mailman/listinfo/python-list</a><br>
</div></div></blockquote></div><br><br clear="all"><br>-- <br>------------------<br>Best Regards<br><br>陈松坚<br>信息科学与技术学院 中山大学 广州大学城 510006<br>Chen Songjian<br>School of Information Science & Technology<br>Sun Yat-sen(Zhongshan) University, Guangzhou Higher Education Mega Center, China, 510006<br>
Mobile: +86-137-6069-6137 <br>Email:  <a href="mailto:csjcg2@gmail.com">csjcg2@gmail.com</a><br>