2
我想解析Yahoo!天氣API,我想保存這些元素的屬性,以供日後使用變量:使用Applescript獲取xml屬性的值
<yweather:location city="Zebulon" region="NC" country="US"/>
<yweather:astronomy sunrise="6:52 am" sunset="7:39 pm"/>
<yweather:forecast day="Wed" date="7 Apr 2010" low="61" high="96" text="Partly Cloudy" code="29" />
我怎樣才能做到這一點使用AppleScript?
所以,
set locationCity to [city]
set locationRegion to [reagion]
set locationCountry to [country]
set astronomySunrise to [sunriseTime]
set astronomySunset to [sunsetTime]
我想forcasts是在某種白天/日期來組織他們