[Tutor] xml parsing from xml
jitendra gupta
jitu.icfai at gmail.com
Wed May 7 15:13:11 CEST 2014
Hi
I just want to create a new xm file from existing xml file. so basically i
want to put contry details in countryName.xml from these file.
I thought to do via read a line by line with normal file handling. but
there a problem with that. So i want to handle python XML . Could you
please suggest on this.
Any Idea is welcome
Thanks & regards
Jitendra
<?xml version="1.0"?><data>
<country name="Liechtenstein">
<rank updated="yes">2</rank>
<year>2008</year>
<gdppc>141100</gdppc>
<neighbor name="Austria" direction="E"/>
<neighbor name="Switzerland" direction="W"/>
</country>
<country name="Singapore">
<rank updated="yes">5</rank>
<year>2011</year>
<gdppc>59900</gdppc>
<neighbor name="Malaysia" direction="N"/>
</country>
<country name="Panama">
<rank updated="yes">69</rank>
<year>2011</year>
<gdppc>13600</gdppc>
<neighbor name="Costa Rica" direction="W"/>
<neighbor name="Colombia" direction="E"/>
</country></data>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/tutor/attachments/20140507/640fb389/attachment.html>
More information about the Tutor
mailing list