title: nokogiri multiple css classes
body: <p>How is it possible to select an html element that have two classes?</p>
  
  <p>For example, how to select the element <code>&lt;p&gt;</code> bellow in an HTML document (given that it has two css classes) <code>class='class1 class2'</code>. </p>
  
  <p>I tried to use the following:</p>
  
  <ul>
  <li><code>doc.xpath("//p[@class~='class1 class2']")</code></li>
  <li><code>doc.xpath("//p[@class~='class1']|[@class~='class2']")</code></li>
  <li><code>doc.xpath("//p[@class~='class1',@class~='class2']")</code></li>
  <li><code>doc.xpath("//p[contains(concat(' ', @class, ' '), ' class1 ') &amp;&amp;   contains(concat(' ',@class, ' '), ' class2 ')]")</code></li>
  </ul>
  
  <p>but without success.</p>
  
  <p>Thanks in advance</p>