Wanting to parse out the the temperature value in the "<w:current" element, 
just after the guid element using ElementTree or xml.sax. 

Still learning python and getting to know the XML terminology, so need to ask 
for help, many thank in advance.


This RSS is from "http://rss.weather.com.au/nsw/newcastle";
===================================================
<?xml version="1.0" encoding="ISO-8859-1"?>
<!-- Weather.com.au RSS Feed must be used in accordance with the terms and 
conditions listed at http://www.weather.com.au/about/rss -->
<rss version="2.0" xmlns:w="http://rss.weather.com.au/w.dtd";>
        <channel>
                <title>Weather.com.au - Newcastle Weather</title>
                <link>http://www.weather.com.au/nsw/newcastle</link>
                <description>Current conditions and forecast for Newcastle, New 
South Wales.</description>
                <language>en-au</language>
                <copyright>Copyright 2013 - Weather.com.au Pty Ltd</copyright>
                <pubDate>Tue, 19 Nov 2013 05:00:00 GMT</pubDate>
                <lastBuildDate>Tue, 19 Nov 2013 05:00:00 GMT</lastBuildDate>
                <ttl>15</ttl>
                <item>
                        <title>Newcastle Current Conditions</title>
                        
<link>http://www.weather.com.au/nsw/newcastle/current</link>
                        <description>
                                <![CDATA[
                                        <b>Temperature:</b> 20.3&deg;C<br />
                                        <b>Dew Point:</b> 18.6&deg;C<br />
                                        <b>Relative Humidity:</b> 90%<br />
                                        <b>Wind Speed:</b> 22.2km/h<br />
                                        <b>Wind Gusts:</b> 29.6km/h<br />
                                        <b>Wind Direction:</b> SSW<br />
                                        <b>Pressure:</b> 0.0hPa<br />
                                        <b>Rain Since 9AM:</b> 0.6mm<br />
                                ]]>
                        </description>
                        <pubDate>Tue, 19 Nov 2013 05:00:00 GMT</pubDate>
                        <guid isPermaLink="false">C1384837200</guid>
                        <w:current temperature="20.3" dewPoint="18.6" 
humidity="90" windSpeed="22.2" windGusts="29.6" windDirection="SSW" 
pressure="0.0" rain="0.6" />
                </item>
                <item>
...etc
===================================================
-- 
https://mail.python.org/mailman/listinfo/python-list

Reply via email to