この次の xmlの場合、xml を取得してから解析して の値を取得するにはどうすればよい<age>
ですか?
<boardgames>
<boardgame objectid="13">
<yearpublished>1995</yearpublished>
<minplayers>3</minplayers>
<maxplayers>4</maxplayers>
<playingtime>90</playingtime>
<age>10</age>
<name sortindex="1">Catan</name>
...
私は現在試しています:
result = urlfetch.fetch(url=game_url)
xml = ElementTree.fromstring(result.content)
しかし、私が正しい道を進んでいるかどうかはわかりません。解析しようとするとエラーが発生します (xml が有効な xml ではないためだと思います)。