I'm not so good at reg exp... Here you are only replacing if the keyword is found in the exact case it is in the $kw array. How can you change that? We have a ton of developers and they never follow standards.
What would be really nice is if it could find them in ANY case, and format them to the right case (and add color colding).
codebit=ereg_replace("([\r\n\\(\\)>, .])$keyword([\r\n <,.$\\(\\)])","\\1<font color=\"#FF0000\">$keyword</font>\\2",$codebit);
|