title: How to read the data or attributes from the xml node "OuterXml"
body: <pre><code>&lt;?xml-stylesheet href="latest_ob.xsl" type="text/xsl"?&gt;
  &lt;current_observation version="1.0" &gt;
      &lt;/image&gt;
      &lt;suggested_pickup&gt;15 minutes after the hour&lt;/suggested_pickup&gt;
      &lt;suggested_pickup_period&gt;60&lt;/suggested_pickup_period&gt;
      &lt;temp_f&gt;44.0&lt;/temp_f&gt;
      &lt;temp_c&gt;6.7&lt;/temp_c&gt;
      &lt;relative_humidity&gt;55&lt;/relative_humidity&gt;
      &lt;wind_string&gt;North at 6.9 MPH (6 KT)&lt;/wind_string&gt;
      &lt;wind_dir&gt;North&lt;/wind_dir&gt;
      &lt;wind_degrees&gt;340&lt;/wind_degrees&gt;
      &lt;wind_mph&gt;6.9&lt;/wind_mph&gt;
      &lt;wind_kt&gt;6&lt;/wind_kt&gt;
      &lt;pressure_string&gt;1025.2 mb&lt;/pressure_string&gt;
      &lt;pressure_mb&gt;1025.2&lt;/pressure_mb&gt;
      &lt;pressure_in&gt;30.28&lt;/pressure_in&gt;
      &lt;dewpoint_string&gt;28.9 F (-1.7 C)&lt;/dewpoint_string&gt;
      &lt;dewpoint_f&gt;28.9&lt;/dewpoint_f&gt;
      &lt;dewpoint_c&gt;-1.7&lt;/dewpoint_c&gt;
  &lt;/current_observation&gt;
  </code></pre>
  
  <p>I want to get some attributes lik <code>wind_dir</code>,<code>wind_kt</code> etc from the above xml data. I have tried this:</p>
  
  <pre><code>var dayt = GetXMLAsString(WeatherXML);
  XDocument doc = XDocument.Parse(dayt);
  
  var r = from element in doc.Elements()
          where element.Name == "latitude"
          select element;
  
  foreach (var item in r)
  {
      Console.WriteLine(item.Value);
  }
  </code></pre>
  
  <p>I want this data to be converted into an array or model to send it to ajax result .</p>