title: Parse xml with namespaces using JQuery and working for all browser ..
body: <p>I'm trying to parse an XML response from a service using JQuery 1.11</p>
  
  <p>At the moment my code works but only in Chrome, not for IE or Firefox and I need it works for all "modern" browsers.</p>
  
  <p>Here you are a sample of my XML</p>
  
  <pre><code>&lt;?xml version='1.0' encoding="ISO-8859-1" ?&gt;
  &lt;wfs:FeatureCollection
     xmlns:ms="http://mapserver.gis.umn.edu/mapserver"
     xmlns:wfs="http://www.opengis.net/wfs"
     xmlns:gml="http://www.opengis.net/gml"
     xmlns:ogc="http://www.opengis.net/ogc"
     xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
     xsi:schemaLocation="http://www.opengis.net/wfs http://schemas.opengis.net/wfs/1.0.0/WFS-basic.xsd 
                         http://mapserver.gis.umn.edu/mapserver http://wms.pcn.minambiente.it/ogc?map=/ms_ogc/wfs/Numeri_Civici_2012.map&amp;amp;SERVICE=WFS&amp;amp;VERSION=1.0.0&amp;amp;REQUEST=DescribeFeatureType&amp;amp;TYPENAME=IN.NUMERICIVICI.2012&amp;amp;OUTPUTFORMAT=XMLSCHEMA"&gt;
        &lt;gml:boundedBy&gt;
          &lt;gml:Box srsName="EPSG:4326"&gt;
              &lt;gml:coordinates&gt;7.700007,44.802147 7.749396,44.849996&lt;/gml:coordinates&gt;
          &lt;/gml:Box&gt;
        &lt;/gml:boundedBy&gt;
      &lt;gml:featureMember&gt;
        &lt;ms:IN.NUMERICIVICI.2012 fid="IN.NUMERICIVICI.2012.2728384"&gt;
  
          &lt;gml:boundedBy&gt;
              &lt;gml:Box srsName="EPSG:4326"&gt;
                  &lt;gml:coordinates&gt;7.735138,44.810267 7.735138,44.810267&lt;/gml:coordinates&gt;
              &lt;/gml:Box&gt;
          &lt;/gml:boundedBy&gt;
          &lt;ms:boundary&gt;
          &lt;gml:Point srsName="EPSG:4326"&gt;
            &lt;gml:coordinates&gt;7.735138,44.810267&lt;/gml:coordinates&gt;
  
          &lt;/gml:Point&gt;
          &lt;/ms:boundary&gt;
          &lt;ms:id&gt;13800026457291&lt;/ms:id&gt;
          &lt;ms:nome&gt;Borgata Tetti Sotto&lt;/ms:nome&gt;
          &lt;ms:civico&gt;16&lt;/ms:civico&gt;
          &lt;ms:istat&gt;01004041&lt;/ms:istat&gt;
          &lt;ms:cap&gt;12030&lt;/ms:cap&gt;
  
          &lt;ms:comune&gt;CARAMAGNA PIEMONTE&lt;/ms:comune&gt;
          &lt;ms:nome_ted&gt; &lt;/ms:nome_ted&gt;
          &lt;ms:provincia&gt;CUNEO&lt;/ms:provincia&gt;
          &lt;ms:regione&gt;PIEMONTE&lt;/ms:regione&gt;
        &lt;/ms:IN.NUMERICIVICI.2012&gt;
      &lt;/gml:featureMember&gt;
      &lt;gml:featureMember&gt;
  
        &lt;ms:IN.NUMERICIVICI.2012 fid="IN.NUMERICIVICI.2012.2736621"&gt;
          &lt;gml:boundedBy&gt;
              &lt;gml:Box srsName="EPSG:4326"&gt;
                  &lt;gml:coordinates&gt;7.735397,44.812403 7.735397,44.812403&lt;/gml:coordinates&gt;
              &lt;/gml:Box&gt;
          &lt;/gml:boundedBy&gt;
          &lt;ms:boundary&gt;
          &lt;gml:Point srsName="EPSG:4326"&gt;
  
            &lt;gml:coordinates&gt;7.735397,44.812403&lt;/gml:coordinates&gt;
          &lt;/gml:Point&gt;
          &lt;/ms:boundary&gt;
          &lt;ms:id&gt;13800026457290&lt;/ms:id&gt;
          &lt;ms:nome&gt;Borgata Tetti Sotto&lt;/ms:nome&gt;
          &lt;ms:civico&gt;25&lt;/ms:civico&gt;
          &lt;ms:istat&gt;01004041&lt;/ms:istat&gt;
  
          &lt;ms:cap&gt;12030&lt;/ms:cap&gt;
          &lt;ms:comune&gt;CARAMAGNA PIEMONTE&lt;/ms:comune&gt;
          &lt;ms:nome_ted&gt; &lt;/ms:nome_ted&gt;
          &lt;ms:provincia&gt;CUNEO&lt;/ms:provincia&gt;
          &lt;ms:regione&gt;PIEMONTE&lt;/ms:regione&gt;
        &lt;/ms:IN.NUMERICIVICI.2012&gt;
  
      &lt;/gml:featureMember&gt;
  </code></pre>
  
  <p></p>
  
  <p>Here you are my code</p>
  
  <pre><code>var xmlText = $('#featureData').text(),
  $xmlData = $.parseXML(xmlText),
  $features = $('featureMember', $xmlData),
  extractedFeatures = [];
  
  $features.each(function () {
  var $this = $(this),
      feature = {},
      items = [
          'nome',
          'civico',
          'istat',
          'cap',
          'comune'
      ],
      item;
  
  for (var i = 0; i &lt; items.length; i++) {
      item = items[i];
      feature[item] = $this.find(item).text();
  }
  
  extractedFeatures.push(feature);
  });
  
  $('#output').text(JSON.stringify(extractedFeatures));
  </code></pre>
  
  <p>and <a href="http://jsfiddle.net/LkM4y/" rel="nofollow">here you are my jsfiddle</a> so you can try it</p>
  
  <p>Any suggestion or workaround? Thank you very much in advance ... </p>
  
  <p>Cesare</p>