Contact: aviboots(AT)netvision.net.il
40,891 questions
53,304 answers
573 users
$s = "This *PHP* code is nice"; $word = "*PHP*"; $s = preg_replace("/" . preg_quote($word, '/') . "/", "<i>" . $word . "</i>", $s); echo $s; /* run: This *PHP* code is nice */