View Single Post
Old 01-13-2015, 07:50 PM   #127
PeterT
Grand Sorcerer
PeterT ought to be getting tired of karma fortunes by now.PeterT ought to be getting tired of karma fortunes by now.PeterT ought to be getting tired of karma fortunes by now.PeterT ought to be getting tired of karma fortunes by now.PeterT ought to be getting tired of karma fortunes by now.PeterT ought to be getting tired of karma fortunes by now.PeterT ought to be getting tired of karma fortunes by now.PeterT ought to be getting tired of karma fortunes by now.PeterT ought to be getting tired of karma fortunes by now.PeterT ought to be getting tired of karma fortunes by now.PeterT ought to be getting tired of karma fortunes by now.
 
Posts: 13,578
Karma: 79436940
Join Date: Nov 2007
Location: Toronto
Device: Libra H2O, Libra Colour
Try making these changes in the weather.py

Change
Code:
weather_link='http://free.worldweatheronline.com/feed/weather.ashx?q={0},{1}&format=xml&num_of_days=5&key=525804183f140652120211'.format(lat, lon)
to
Code:
weather_link='http://api.worldweatheronline.com/free/v2/weather.ashx?q={0},{1}&format=xml&num_of_days=5&key=95f758b5c88e1b323c12bd1017202'.format(lat, lon)
(note the new URL and the new key value).

Change
Code:
h_temps = dom.getElementsByTagName('tempMax%s' % unit)
l_temps = dom.getElementsByTagName('tempMin%s' % unit)
to
Code:
h_temps = dom.getElementsByTagName('maxtemp%s' % unit)
l_temps = dom.getElementsByTagName('mintemp%s' % unit)
PeterT is offline   Reply With Quote