title: Select and copy a content from a website
body: <p>Im trying to extract a part of my website to get some content information. The content of that I'm trying to put into a variable is like:</p>
  
  <pre><code> &lt;table  class="tabelaHistorico"&gt;
                &lt;tr&gt; 
                  &lt;td bgcolor=#ccccc&gt;&lt;/td&gt;
                  &lt;td bgcolor=#ccccc&gt;2014&lt;/td&gt;
                &lt;/tr&gt;
  
                &lt;tr&gt; 
                  &lt;td&gt; 
                    Jan
                  &lt;/td&gt;
                  &lt;td&gt; 
                    9719,46
                  &lt;/td&gt;
                &lt;/tr&gt;
  
                &lt;tr&gt; 
                  &lt;td&gt; 
                    Fev
                  &lt;/td&gt;
                  &lt;td&gt; 
                    9421,65
                  &lt;/td&gt;
                &lt;/tr&gt;
    &lt;/table&gt;
  </code></pre>
  
  <p>I tried to do:</p>
  
  <pre><code> $content = file_get_contents("www.website.com");
   $pos = strpos($content,"table" , 0);
   echo $pos;
   printf($pos);
   $rest = substr($content, $pos, 5);
   echo $rest;
  </code></pre>