title: How do I get the value of a <pre> tag with no ID?
body: <p>I have the following code set up from an example:</p>
  
  <pre><code>&lt;?php
  $url = 'http://somedomain/something';
  $content = file_get_contents($url);
  $first_step = explode( '&lt;div id="somediv"&gt;' , $content );
  $second_step = explode("&lt;/div&gt;" , $first_step[1] );
  
  echo $second_step[0];
  
  ?&gt;
  </code></pre>
  
  <p>The problem here is that the website from which I'm trying to fetch the value of the pre tag has no ID:</p>
  
  <pre><code>&lt;pre&gt;some content&lt;/pre&gt;
  </code></pre>
  
  <p>I've also tried this but no success so far:</p>
  
  <pre><code>&lt;?php
  $url = 'http://somedomain/something';
  $content = file_get_contents($url);
  $first_step = explode( '&lt;script&gt;document.getElementsByTagName("pre")' , $content );
  $second_step = explode("&lt;/script&gt;" , $first_step[1] );
  
  echo $second_step[0];
  
  ?&gt;
  </code></pre>
  
  <p>Basically, I'm trying to fetch a value from a domain which is wrapped by a <code>pre</code> tag with no additional identifiers. Any help appreciated!</p>