how to count the number of times a word occurs on a webpage with PHP
<p>I need a script that will return a count of how many times a specified word appears on webpage.  Does anyone know how to do this with PHP?  The code will be like this:</p>

<pre><code>&lt;?php
$url="watever.com";
the script here
echo(result);
?&gt;
</code></pre>

<p>I do have this little bit that just gives a count of how many times every word on the webpage appears but I am not quite sure how to modify it for just one word.</p>

<pre><code>$str = file_get_contents('http://www.example.com/');
print_r(array_count_values(str_word_count(strip_tags(strtolower($str)), 1)));
</code></pre>
