PHP Preg_Match in string for blacklist words
<p>I would like to have the code look for wildcards in the preg_match search.  For example, right now it only finds the word Dumps..  If the word is dumpster, I would like for it to be able trigger..</p>

<p>Thanks in advance!</p>

<pre><code>$aSpam= array
( 'Cvv'=&gt; ''
, 'Dumps'=&gt; 'i'
, 'acc Paypal'=&gt; 'i'
);

foreach( $aSpam as $sWord=&gt; $sOption )
if( preg_match( '#\\b'. preg_quote( $sWord, '#' ). '\\b#'. $sOption, $message_parser-&gt; message ) ) {
    $error[]= 'Spam detected';
    break;
}
</code></pre>
