title: Access XML nodes in parse string
body: <p>I'm receiving XML from a server in a different domain, by performing an Ajax call through a PHP proxy (to work around the cross-origin "issue"). I don't get the value from the XML nodes into my html tag. No errors in my browser console. In Firebug, I can see the XML data just fine in both the Response and XML column. Complete code:</p>
  
  <pre><code>&lt;!DOCTYPE html&gt;
  &lt;html&gt;
  &lt;head&gt;
  &lt;meta charset="utf-8" /&gt;
  &lt;/head&gt;
  &lt;body&gt;
  &lt;script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/jquery/2.1.3/jquery.min.js"&gt;&lt;/script&gt;
  &lt;h2&gt;Flightinfo&lt;/h2&gt;
  
  &lt;button type="button" onclick="loadXMLDoc()"&gt;
  Get Flight ID&lt;/button&gt;
  
  &lt;p id="fid"&gt;&lt;/p&gt;
  
  &lt;script&gt;
  function loadXMLDoc() {
  jQuery(document).ready(function($) { 
    $.ajax({
      url: "http://d2f.no/flightinfo/proxy.php",
      type: "POST",
      data: {
          address: "http://flydata.avinor.no/XmlFeed.asp?TimeFrom=1&amp;TimeTo=7&amp;airport=OSL&amp;direction=D&amp;lastUpdate=2016-03-10T15:03:00Z"
      },
  
      success: function myFunction(xml) {
  
    var x, i, xmlDoc, txt, parser;
    parser = new DOMParser(); // new Parser
    xmlDoc = parser.parseFromString(xmlDoc,"text/xml"); // Parse string
    txt = "";
    x = xmlDoc.getElementsByTagName("flight_id");
    for (i = 0; i&lt; x.length; i++) {
    txt += x[i].childNodes[0].nodeValue + "&lt;br&gt;";
    }
  
     document.getElementById("fid").innerHTML = txt;
  
  }
  
    }); 
  });  
  }
  &lt;/script&gt;
  &lt;/body&gt;
  &lt;/html&gt;
  </code></pre>
  
  <p>Parts of the XML data received:</p>
  
  <pre><code>    &lt;airport xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="http://flydata.avinor.no/XmlFeed.xsd" name="OSL"&gt;
  &lt;flights lastUpdate="2016-04-07T00:37:16Z"&gt;
  &lt;flight uniqueID="5760860"&gt;
  &lt;airline&gt;OSL&lt;/airline&gt;
  &lt;flight_id&gt;OSL424&lt;/flight_id&gt;
  &lt;dom_int&gt;D&lt;/dom_int&gt;
  &lt;schedule_time&gt;2016-03-10T10:15:00Z&lt;/schedule_time&gt;
  &lt;arr_dep&gt;D&lt;/arr_dep&gt;
  &lt;airport&gt;BDU&lt;/airport&gt;
  &lt;gate&gt;PAD&lt;/gate&gt;
  &lt;/flight&gt;
  &lt;flight uniqueID="5758058"&gt;
  &lt;airline&gt;AC&lt;/airline&gt;
  &lt;flight_id&gt;AC6377&lt;/flight_id&gt;
  &lt;dom_int&gt;S&lt;/dom_int&gt;
  &lt;schedule_time&gt;2016-03-11T05:30:00Z&lt;/schedule_time&gt;
  &lt;arr_dep&gt;D&lt;/arr_dep&gt;
  &lt;airport&gt;BRU&lt;/airport&gt;
  &lt;check_in&gt;10&lt;/check_in&gt;
  &lt;/flight&gt;
  </code></pre>
  
  <p><a href="http://flydata.avinor.no/XmlFeed.asp?TimeFrom=1&amp;TimeTo=7&amp;airport=OSL&amp;direction=D&amp;lastUpdate=2016-03-10T15:03:00Z" rel="nofollow">Link to XML feed</a></p>
  
  <p>What am I missing here?</p>