Ejemplo de archivo XML
Código:
<?xml version="1.0" encoding="ISO-8859-1"?> <!--This document is intended only for use by authorized licensees of The Weather Channel. Unauthorized use is prohibited. Copyright 1995-2005, The Weather Channel Interactive, Inc. All Rights Reserved.--> <weather ver="2.0"> <head> <locale>en_US</locale> <form>MEDIUM</form> <ut>C</ut> <ud>km</ud> <us>km/h</us> <up>mb</up> <ur>mm</ur> </head> <loc id="MXSR0159"> <dnam>Ciudad Obregon, Mexico</dnam> <tm>11:10 AM</tm> <lat>27.49</lat> <lon>-109.94</lon> <sunr>7:08 AM</sunr> <suns>5:33 PM</suns> <zone>-7</zone> </loc> <cc> <lsup>12/26/07 10:48 AM Local Time</lsup> <obst>Ciudad Obregon, Mexico</obst> <tmp>15</tmp> <flik>15</flik> <t>Sunny</t> <icon>32</icon> <bar> <r>1017.3</r> <d>falling</d> </bar> <wind> <s>14</s> <gust>N/A</gust> <d>300</d> <t>WNW</t> </wind> <hmid>36</hmid> <vis>16.1</vis> <uv> <i>3</i> <t>Moderate</t> </uv> <dewp>0</dewp> <moon> <icon>17</icon> <t>Waning Gibbous</t> </moon> </cc> <dayf> <lsup>12/26/07 8:17 AM Local Time</lsup> <day d="0" t="Wednesday" dt="Dec 26"> <hi>19</hi> <low>12</low> <sunr>7:08 AM</sunr> <suns>5:33 PM</suns> <part p="d"> <icon>32</icon> <t>Sunny</t> <wind> <s>14</s> <gust>N/A</gust> <d>326</d> <t>NW</t> </wind> <bt>Sunny</bt> <ppcp>0</ppcp> <hmid>31</hmid> </part> <part p="n"> <icon>33</icon> <t>Mostly Clear</t> <wind> <s>11</s> <gust>N/A</gust> <d>309</d> <t>NW</t> </wind> <bt>M Clear</bt> <ppcp>0</ppcp> <hmid>42</hmid> </part> </day> <day d="1" t="Thursday" dt="Dec 27"> <hi>19</hi> <low>10</low> <sunr>7:09 AM</sunr> <suns>5:34 PM</suns> <part p="d"> <icon>34</icon> <t>Mostly Sunny</t> <wind> <s>18</s> <gust>N/A</gust> <d>329</d> <t>NNW</t> </wind> <bt>M Sunny</bt> <ppcp>0</ppcp> <hmid>38</hmid> </part> <part p="n"> <icon>33</icon> <t>Mostly Clear</t> <wind> <s>19</s> <gust>N/A</gust> <d>342</d> <t>NNW</t> </wind> <bt>M Clear</bt> <ppcp>0</ppcp> <hmid>31</hmid> </part> </day> <day d="2" t="Friday" dt="Dec 28"> <hi>20</hi> <low>12</low> <sunr>7:09 AM</sunr> <suns>5:34 PM</suns> <part p="d"> <icon>34</icon> <t>Mostly Sunny</t> <wind> <s>16</s> <gust>N/A</gust> <d>336</d> <t>NNW</t> </wind> <bt>M Sunny</bt> <ppcp>0</ppcp> <hmid>30</hmid> </part> <part p="n"> <icon>33</icon> <t>Mostly Clear</t> <wind> <s>11</s> <gust>N/A</gust> <d>327</d> <t>NNW</t> </wind> <bt>M Clear</bt> <ppcp>0</ppcp> <hmid>33</hmid> </part> </day> <day d="3" t="Saturday" dt="Dec 29"> <hi>21</hi> <low>13</low> <sunr>7:09 AM</sunr> <suns>5:35 PM</suns> <part p="d"> <icon>34</icon> <t>Mostly Sunny</t> <wind> <s>11</s> <gust>N/A</gust> <d>332</d> <t>NNW</t> </wind> <bt>M Sunny</bt> <ppcp>0</ppcp> <hmid>32</hmid> </part> <part p="n"> <icon>31</icon> <t>Clear</t> <wind> <s>10</s> <gust>N/A</gust> <d>334</d> <t>NNW</t> </wind> <bt>Clear</bt> <ppcp>0</ppcp> <hmid>40</hmid> </part> </day> <day d="4" t="Sunday" dt="Dec 30"> <hi>23</hi> <low>14</low> <sunr>7:10 AM</sunr> <suns>5:35 PM</suns> <part p="d"> <icon>32</icon> <t>Sunny</t> <wind> <s>11</s> <gust>N/A</gust> <d>336</d> <t>NNW</t> </wind> <bt>Sunny</bt> <ppcp>0</ppcp> <hmid>39</hmid> </part> <part p="n"> <icon>33</icon> <t>Mostly Clear</t> <wind> <s>10</s> <gust>N/A</gust> <d>331</d> <t>NNW</t> </wind> <bt>M Clear</bt> <ppcp>0</ppcp> <hmid>45</hmid> </part> </day> </dayf> </weather>