Welcome Guest, Not a member yet? Register   Sign In
exclude from being replaced

hi guys. please help me with this problem thank you very much
how to exclude the one with link from being replaced?

$find = "web design";
$string = "WEB DESIGN Web Design web design <a href='google.com'>Web design las vegas</a>";
$finalstring = preg_replace('/('.$find.'\b)/iU', '<a href="http://google.com">\1</a>', $string,-1,$i);
echo $finalstring;
echo '<br />'.$i;

Thanks for helping.

please help regexp experts.. pls. help.. tnx a lot

Theme © iAndrew 2016 - Forum software by © MyBB