PHP: Detect words in text or string
<p>I have a long text, and I have 5 words given.</p>

<p>I'd like to be able to parse the text and highlight those 5 words with 5 different styles.</p>

<p>I'm working with php and js/jquery.</p>

<p>what's the best practice to accomplish this?</p>

<p>is enough a <code>str_replace('word','&lt;span style1 &gt;word&lt;/span&gt;', $text)?</code></p>

<p>NOTE:
what about when the word is uppercase or capitalized?</p>
