A subset of the live weather details from our weather station have been exposed
as an XML Web Service.
The url to the web service is http://weather.cobbnz.com/weatherservice/webservice.asmx
Another simple web page that returns XML has also been written that will allow you
to simply extract relevant details
from our current weather data.
<
weather
>
<TemperatureCurrent>6.06</TemperatureCurrent>
<TemperatureFeelsLike>6.3</TemperatureFeelsLike>
<TemperatureAllTimeMin>-5.2</TemperatureAllTimeMin>
<TemperatureAllTimeMinDateTime>8/Jul/2007 07:58:00</TemperatureAllTimeMinDateTime>
<TemperatureAllTimeMax>34.9</TemperatureAllTimeMax>
<TemperatureAllTimeMaxDateTime>6/Feb/2011 03:44:00</TemperatureAllTimeMaxDateTime>
<TemperatureThisYearMin>-0.5</TemperatureThisYearMin>
<TemperatureThisYearMinDateTime>20/May/2012 07:35:00</TemperatureThisYearMinDateTime>
<TemperatureThisYearMax>28.4</TemperatureThisYearMax>
<TemperatureThisYearMaxDateTime>5/Jan/2012 04:20:00</TemperatureThisYearMaxDateTime>
<TemperatureTrend>Rising</TemperatureTrend>
<HeatIndexMax>6.1</HeatIndexMax>
<HeatIndexMin>0.6</HeatIndexMin>
<HeatIndex>6.1</HeatIndex>
<UV>0.0</UV>
<Barometer>1019.0</Barometer>
<BarometerTrend>Rising</BarometerTrend>
<Humidex>4.7</Humidex>
<Humidity>80</Humidity>
<HumidityTrend>Rising</HumidityTrend>
<DewPoint>2.9</DewPoint>
<WindAvgSpeed>0.7</WindAvgSpeed>
<WindChill>6.1</WindChill>
<WindChillMin>0.6</WindChillMin>
<WindChillMax>6.1</WindChillMax>
<WindDirection>277</WindDirection>
<WindDirectionAverage>277</WindDirectionAverage>
<RainToday>0.0</RainToday>
<CloudHeight>1394.2</CloudHeight>
<SunRise>7:42AM</SunRise>
<SunSet>5:10PM</SunSet>
<MoonRise>7:42AM</MoonRise>
<MoonSet>4:27PM</MoonSet>
<MoonPhase>0</MoonPhase>
<Weather>Cloudy/Dry</Weather>
<Icon>5</Icon>
<Forecast>mostly clear with little temp. change.</Forecast>
<ForecastIcon>5</ForecastIcon>
<Date>21/May/2012</Date>
<Time>08:18:46</Time>
<Reading>Monday, 21 May, 2012 08:18:46</Reading>
<ReadingTime>8:18 AM</ReadingTime>
<StationName>Fendalton-8:18:46 AM</StationName> </weather>
The url to return just simple XML like shown above is:
http://weather.cobbnz.com/weatherservice/xml.aspx
Note: To display the data in this HTML page I used an XSL Stylesheet along with the XML data.
However you may specify a parameter to the URL ( WebServerURL) which is the path
to someone else's client
raw data, this will allow you to use our service to get
data from other sites and render that how you want.
<
weather
>
<TemperatureCurrent>6.06</TemperatureCurrent>
<TemperatureFeelsLike>6.3</TemperatureFeelsLike>
<TemperatureAllTimeMin>-5.2</TemperatureAllTimeMin>
<TemperatureAllTimeMinDateTime>8/Jul/2007 07:58:00</TemperatureAllTimeMinDateTime>
<TemperatureAllTimeMax>34.9</TemperatureAllTimeMax>
<TemperatureAllTimeMaxDateTime>6/Feb/2011 03:44:00</TemperatureAllTimeMaxDateTime>
<TemperatureThisYearMin>-0.5</TemperatureThisYearMin>
<TemperatureThisYearMinDateTime>20/May/2012 07:35:00</TemperatureThisYearMinDateTime>
<TemperatureThisYearMax>28.4</TemperatureThisYearMax>
<TemperatureThisYearMaxDateTime>5/Jan/2012 04:20:00</TemperatureThisYearMaxDateTime>
<TemperatureTrend>Rising</TemperatureTrend>
<HeatIndexMax>6.1</HeatIndexMax>
<HeatIndexMin>0.6</HeatIndexMin>
<HeatIndex>6.1</HeatIndex>
<UV>0.0</UV>
<Barometer>1019.0</Barometer>
<BarometerTrend>Rising</BarometerTrend>
<Humidex>4.7</Humidex>
<Humidity>80</Humidity>
<HumidityTrend>Rising</HumidityTrend>
<DewPoint>2.9</DewPoint>
<WindAvgSpeed>0.7</WindAvgSpeed>
<WindChill>6.1</WindChill>
<WindChillMin>0.6</WindChillMin>
<WindChillMax>6.1</WindChillMax>
<WindDirection>277</WindDirection>
<WindDirectionAverage>277</WindDirectionAverage>
<RainToday>0.0</RainToday>
<CloudHeight>1394.2</CloudHeight>
<SunRise>7:42AM</SunRise>
<SunSet>5:10PM</SunSet>
<MoonRise>7:42AM</MoonRise>
<MoonSet>4:27PM</MoonSet>
<MoonPhase>0</MoonPhase>
<Weather>Cloudy/Dry</Weather>
<Icon>5</Icon>
<Forecast>mostly clear with little temp. change.</Forecast>
<ForecastIcon>5</ForecastIcon>
<Date>21/May/2012</Date>
<Time>08:18:46</Time>
<Reading>Monday, 21 May, 2012 08:18:46</Reading>
<ReadingTime>8:18 AM</ReadingTime>
<StationName>Fendalton-8:18:46 AM</StationName> </weather>
The data above is coming from Weather Station - ZL3GP, Burwood, Christchurch,
New Zealand
The url to return the XML data from ZL3GP is:
http://weather.cobbnz.com/weatherservice/xml.aspx?WebServerURL=http://www.zl3gp.co.nz
Here is an example of taking the data from here and processing it using XSL and
rendering just the temperature.
XSL Document
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xsl:output method="html"/>
<xsl:template match="/Weather">
The current weather temperature is <xsl:value-of select="TemperatureCurrent"></xsl:value-of>
</xsl:template>
</xsl:stylesheet>
Rendered Result
The current weather temperature is 6.06
|