title: Using jQuery to copy an XML node to another XML file?
body: <p>I'm trying to aggregate data from a number of different xml sources into a single xml file using either JavaScript or jQuery. I'm looping over the files, using jquery $.Ajax to read the file, and am selecting the first node (the node I want) and want to copy and append it to my destination xml file, then move on.</p>
  
  <p>I can select the first row using:</p>
  
  <pre><code>firstRow = $(testThis.responseXML).find("z\\:row:eq(0)"); // get the first row
   alert('firstRow : ' + firstRow  );  // check the node text
  </code></pre>
  
  <p>But I can't seem to copy the node and append it. I'm trying to use:</p>
  
  <pre><code>newXMLData.append($(firstRow).text()); // append row to new xml file
  </code></pre>
  
  <p>I've tried using .text(), .HTML(), .val() but nothing seems to work.  </p>
  
  <p>Any ideas?</p>