Text extractor php
<p>I have this page <a href="http://inviatapenet.gethost.ro/sop/test1.php" rel="nofollow">test1.php</a> on this other page <a href="http://inviatapenet.gethost.ro/sop/test.php" rel="nofollow">test.php</a> i have this php code running:</p>

<pre><code> &lt;?php 
    libxml_use_internal_errors(true); 
    $doc = new DOMDocument(); 
    $doc-&gt;loadHTMLFile("http://inviatapenet.gethost.ro/sop/test1.php"); 
    $xpath = new DOMXpath($doc); 
    $elements = $xpath-&gt;query("//*[@type='text/javascript']/@fid");
        if (!is_null($elements)) {
            foreach ($elements as $element) {
                $nodes = $element-&gt;childNodes;
                foreach ($nodes as $node) {
                    echo $node-&gt;nodeValue. "\n";
                }
            }
        }
?&gt;
</code></pre>

<p>But shows nothing.</p>

<p>i'm trying to get from that page, only the content of fid="x8qfp3cvzbxng8e" :</p>

<p>From this Line </p>

<pre><code>&lt;script type="text/javascript"&gt; fid="x8qfp3cvzbxng8e"; v_width=640;
v_height=360; &lt;/script&gt;
</code></pre>

<p>The output shold be:</p>

<blockquote>
  <p>x8qfp3cvzbxng8e</p>
</blockquote>

<p>Wath I have to do?</p>
