strip_tags will strip all the tags, such as images etc. only return pure text?
so i may use the strip_tags to strip all the tags from the rich text value and save the pure text in another field and search the database in the pure text field.
Is that the best solution for my question?
But now, I have another question, I want to high light the "search word" in the term defination display page which is rich text.
So how can I high light the "search word" in the rich text field but I got the search results from searching in the pure text field.
Such as if I search "comptuer CPU" in the pure text field, and then return the rich text fields values as the search result. But How can I know that "computer <b>CPU</b>" should be highlighted.
Thanks!