Hi Stefan,
Thanks for the code review :) Only just noticed this.
On Wed, May 25, 2011 at 3:10 PM, Stefan Behnel wrote:
> Sithembewena Lloyd Dube, 25.05.2011 14:40:
>
> Thanks for all your suggestions. I read up on gzip and urllib and also
>> learned in the process that I could use urllib2 as i
Sithembewena Lloyd Dube, 25.05.2011 14:40:
Thanks for all your suggestions. I read up on gzip and urllib and also
learned in the process that I could use urllib2 as its the latest form of
that library.
Herewith my solution: I don't know how elegant it is, but it works just
fine.
def get_contest
Hi Everyone,
Thanks for all your suggestions. I read up on gzip and urllib and also
learned in the process that I could use urllib2 as its the latest form of
that library.
Herewith my solution: I don't know how elegant it is, but it works just
fine.
def get_contests():
url = '
http://xml.ma
Sithembewena Lloyd Dube, 24.05.2011 11:59:
I am trying to parse an XML feed and display the text of each child node
without any success. My code in the python shell is as follows:
>>> import urllib
>>> from xml.etree import ElementTree as ET
>>> content = urllib.urlopen('
http://xml.matchbook.c
"Sithembewena Lloyd Dube" wrote
And now, to iterate through its child nodes and print out the text
of each
node:
for node in xml_content.getiterator('contest'):
...name = node.attrib.get('text')
...print name
...
Nothing is printed,
i = 0
for node in xml_content.geti
Hi Everyone,
I am trying to parse an XML feed and display the text of each child node
without any success. My code in the python shell is as follows:
>>>import urllib
>>>from xml.etree import ElementTree as ET
>>>content = urllib.urlopen('
http://xml.matchbook.com/xmlfeed/feed?sport-id=&vendor=T