title: How to remove an xml element from file?
body: <p>In an XML file such as :</p>
  
  <pre><code>&lt;Snippets&gt;
   &lt;Snippet name="abc"&gt;
     &lt;SnippetCode&gt;
     code goes here
     &lt;/SnippetCode&gt;
   &lt;/Snippet&gt;
  
   &lt;Snippet name="def"&gt;
     &lt;SnippetCode&gt;
     code goes here
     &lt;/SnippetCode&gt;
   &lt;/Snippet&gt;
  &lt;/Snippets&gt;
  </code></pre>
  
  <p>How can I remove an element when only its attribute name (like <code>abc</code> or <code>def</code>) is given?</p>