- Impact
- 18
When you search in a search engine, your search terms go bold...
I want every word in a string to be found in another string and turn bold.
$q is the query from a user (eg: football results)
$result[1][snippet] is the snippet of test associated with the first result (eg: The best type football is where the results are good.)
I want to output "The best type of football is where the results are good."
How can I do this?
Thanks
Tom
Done... thanks... -
I exploded the $q variable by " " (a space) and then did an eregi_replace on the snippet!
I want every word in a string to be found in another string and turn bold.
$q is the query from a user (eg: football results)
$result[1][snippet] is the snippet of test associated with the first result (eg: The best type football is where the results are good.)
I want to output "The best type of football is where the results are good."
How can I do this?
Thanks
Tom
Done... thanks... -
I exploded the $q variable by " " (a space) and then did an eregi_replace on the snippet!







