title: Copying tag values from one XML to another using XSLT
body: <p>I have two xml files, say <strong>file1.xml</strong> which is as follows:</p>
  
  <pre><code>&lt;?xml version="1.0"?&gt;
  &lt;root &gt;
      &lt;text id='a'&gt;This is to be replaced&lt;/text&gt;
      &lt;note&gt;This should not be touched&lt;/note&gt;
      &lt;text id='b'&gt;This is intact&lt;/text&gt;
  &lt;/root&gt;
  </code></pre>
  
  <p><strong>file2.xml</strong> is as follows</p>
  
  <pre><code>&lt;?xml version="1.0"?&gt;
  &lt;root &gt;
      &lt;text id='a'&gt;Replacement Text&lt;/text&gt;
      &lt;note&gt;This is a personal note&lt;/note&gt;
  &lt;/root&gt;
  </code></pre>
  
  <p>I expect an output xml file of the form :</p>
  
  <p><strong>output.xml</strong></p>
  
  <pre><code>&lt;?xml version="1.0"?&gt;
  &lt;root&gt;
      &lt;text id='a'&gt;Replacement Text&lt;/text&gt;
      &lt;note&gt;This should not be touched&lt;/note&gt;
      &lt;text id='b'&gt;This is intact&lt;/text&gt;
  &lt;/root&gt;
  </code></pre>
  
  <p>Please help me with a xsl to get the desired output. This is not a homework and I am trying to understand xslt.</p>