Donna
|
| Posted: 02/21/2002, 12:04 PM |
|
I use the following php code to highlight each occurrence of the keyword in my search results. The only problem is, the highlights (not the returned records) are case sensitive. So, if the keyword is "man", then "man" will be highlighted but "Man" will not. Is there a parameter that can be set in the get_param line (or elsewhere) that will make the highlight case insensitive?
if (get_param("article_title") != "" )
{
$string_to_split = get_param("article_title");
$tok = split(" ", $string_to_split);
$size = sizeof($tok);
for ($i = 0; $i < $size; $i++)
$fldname = str_replace($tok[$i], "<font color = red>". $tok[$i] ."</font>", $fldname);
}
Thanks,
Donna
|
|
|
 |
Alex Alexapolsky
|
| Posted: 02/22/2002, 1:03 AM |
|
It's not parameter case sensetivity matters , all you need to do is
form a case insensetive sql statement where both parameter and searchable
field are casted to lower or upper case
|
|
|
 |
|