check if a string contain multiple specific words
<p>How to check if a string contain multiple specific words, now i can check single words using this code:</p>

<pre><code>&lt;?php
$data = "text text text text text text text bad text text naughty";
if (strpos($data, 'bad') !== false) {
echo 'true';
}
?&gt;
</code></pre>

<p>But i want to add more words to check something like this:</p>

<pre><code>&lt;?php
$data = "text text text text text text text bad text text naughty";
if (strpos($data, 'bad || naughty') !== false) {
echo 'true';
}
?&gt;
</code></pre>

<p>this not working,<br><strong>if one of the words was found then it should return true</strong> any ideas?</p>
