Hi...
I need to post weather information on my website. I receive a xml file every 30 mintues. I am having trouble extracting the attributes of the file so I can post just the temp and the sky information on my asp page. I have seen examples of extracting the elements but not the attrributes. Also I need the extraction to work in both IE and Netscape.
xml file:
<?xml version="1.0"?>
<WEATHER>
<WXWSOBS STATIONID="KTPA" TEMPERATURE="84" DEWPOINT="73" RELATIVEHUMIDITY="69" WINDSPEED="10" WINDDIRECTION="280" GUST="" PRESSURE="30.03" WEATHER="" SKY="Broken Clouds" CEILING="25000" VISIBILITY="10" HEATINDEX="91" WINDCHILL="84" SNOWDEPTH="" SIXHRMAX="88" TWENTYFOURHRMAX="" SIXHRMIN="79" TWENTYFOURHRMIN="" THREEHRPRECIP="" SIXHRPRECIP="Trace" TWENTYFOURHRPRECIP="" UPDATETIME="2004-7-26T18:00:00" />
</WEATHER>
Summary:
- pull xml data from a file
- Data needed:
- TEMPERATURE, SKY
- listed like: 84F, Broken Clouds
Thank for any help provided.
Roger
I need to post weather information on my website. I receive a xml file every 30 mintues. I am having trouble extracting the attributes of the file so I can post just the temp and the sky information on my asp page. I have seen examples of extracting the elements but not the attrributes. Also I need the extraction to work in both IE and Netscape.
xml file:
<?xml version="1.0"?>
<WEATHER>
<WXWSOBS STATIONID="KTPA" TEMPERATURE="84" DEWPOINT="73" RELATIVEHUMIDITY="69" WINDSPEED="10" WINDDIRECTION="280" GUST="" PRESSURE="30.03" WEATHER="" SKY="Broken Clouds" CEILING="25000" VISIBILITY="10" HEATINDEX="91" WINDCHILL="84" SNOWDEPTH="" SIXHRMAX="88" TWENTYFOURHRMAX="" SIXHRMIN="79" TWENTYFOURHRMIN="" THREEHRPRECIP="" SIXHRPRECIP="Trace" TWENTYFOURHRPRECIP="" UPDATETIME="2004-7-26T18:00:00" />
</WEATHER>
Summary:
- pull xml data from a file
- Data needed:
- TEMPERATURE, SKY
- listed like: 84F, Broken Clouds
Thank for any help provided.
Roger