title: Extract Sales rank from a website
body: <p>I am trying to extract Sales rank of kindle books from <a href="https://rads.stackoverflow.com/amzn/click/com/B003XF1XOQ" rel="nofollow noreferrer" rel="nofollow noreferrer">this amazon site</a>.</p>
  
  <p>In the above case the sales rank is 3 (element name "<code>SalesRank</code>")</p>
  
  <p>This is what i have tried till now </p>
  
  <pre><code>$xpath_kindle-&gt;query("//li[@id='SalesRank']")-&gt;item(0)-&gt;nodeValue;
  </code></pre>
  
  <p>any help is greatly appreciated</p>