title: Powershell: how to use xpath to filter by attribute and content at the same time?
body: <p>I have this script:</p>
  
  <pre><code>function f3
  {
  [xml]$xml = @"
  &lt;?xml version="1.0" encoding="utf-8"?&gt;
  &lt;Book&gt;
    &lt;projects&gt;
      &lt;project name="Book1" date="2009-01-20"&gt;
        &lt;editions&gt;
          &lt;edition language="English"&gt;Novel_1&lt;/edition&gt;
          &lt;edition language="English"&gt;my.Book1.com&lt;/edition&gt;
          &lt;edition language="German"&gt;Ge.Book1.Com&lt;/edition&gt;
          &lt;edition language="French"&gt;Fr.Book1.com&lt;/edition&gt;
          &lt;edition language="Polish"&gt;Pl.Book1.com&lt;/edition&gt;
          &lt;edition language="English"&gt;Novel_2&lt;/edition&gt;
          &lt;edition language="English"&gt;FairyTale&lt;/edition&gt;
        &lt;/editions&gt;
      &lt;/project&gt;
    &lt;/projects&gt;
  &lt;/Book&gt;
  "@
  
  $xml.SelectNodes("/Book/projects/editions")
  }
  f3
  </code></pre>
  
  <p>I wish to select "language=English", with content either contains "Novel" or equals "FairyTale", so my expected output is:</p>
  
  <pre><code>Novel_1
  Novel_2
  FairyTale
  </code></pre>
  
  <p>So how can I change my "SelectNodes" statement?
  Thanks a lot!</p>