title: Count number of xml nodes using JQuery
body: <p>I know this question has been answered multiple time, but for some reason the code does not work for me. My xml is in this format:</p>
  
  <pre><code>&lt;Row&gt;
  &lt;data&gt;&lt;/data&gt;
  ....
  &lt;/Row&gt;
  </code></pre>
  
  <p>I am trying to count the number of rows I have in the file. The code I have so far:</p>
  
  <pre><code>$.ajax({
  type: "GET",
  url: "xmloutput.xml",
  cache: false,
  dataType: "xml",
  success: function(xml) {
  
      if (window.XMLHttpRequest) {
          xhttp = new XMLHttpRequest();
          console.log('non-IE browser');
      } else {    // IE
          console.log('IE browser')
          xhttp = new ActiveXObject("Microsoft.XMLHTTP");
      }
  
      console.log("number of rows:" + $(xml).find('Row').each(function(){}).length);
  </code></pre>
  
  <p>My console display:</p>
  
  <pre><code>non-IE browser
  number of rows:8
  </code></pre>
  
  <p>The actual number of rows is 520. Firebug also says that my Javascript is error free. Whats going on?</p>