Highlight search terms


I can't seem to find a configurable Ruby search term highlighter out
there - can't believe there isn't one ?

I've reviewed TextHelper.highlight but it's to simple for my
requirements. I need to be able to exclude html when highlighting.
Something similar to PHP str_highlight :


If no suggestions then I guess I'll have to write some code :wink: