title: Javascript/XML - Getting the node name
body: <p>I need to get the the name of the tag "myChild" and the "content".
  This is simple, but i am stuck, sleepy and here is what I get with my tests:</p>
  
  <p>XML:</p>
  
  <pre><code>...
  &lt;myParent&gt;
    &lt;myChild&gt;content&lt;/myChild&gt;
  &lt;/myParent&gt;
  &lt;myParent&gt;
    &lt;myChild&gt;content&lt;/myChild&gt;
  &lt;/myParent&gt;
  ...
  </code></pre>
  
  <p>JS:</p>
  
  <pre><code>var x=xmlDoc.getElementsByTagName("myParent");
  alert(x[1].childNodes[0].nodeName); //returns "#text" - "myChild" needed
  alert(x[1].childNodes[0].nodeValue); //returns "" - "content" needed
  </code></pre>