Hello!
Ai have the following situation:
A search engine, after keywords, in multiple columns of a table.
In the search result i want to highlight the keywords used, using css, or whatever. But i have a problem with case-sensitive.
For example:
$text = "The QUICK brown fox jumps over the lazy dog <br>";
echo $text;
$keyword = "quick";
$text = eregi_replace ($keyword,"<font color='red'>$keyword</font>", $text);
echo $text;
The result is:
The QUICK brown fox jumps over the lazy dog
The quick brown fox jumps over the lazy dog
How can i make to have this result:
The QUICK brown fox jumps over the lazy dog
The QUICK brown fox jumps over the lazy dog
I don't want to change the characters, in this case, from big caps to small caps, i want the keyword to remain the same like in original, just highlight.
Thanks!
p.s. i don't have PHP5, to use [FONT=courier new]str_ireplace[/FONT] , if this is the solution