Suppose I have a container:
This is a red apple
How to color a word \"red\" with red color? Some
Here's some code that uses jQuery to wrap a class around the word red, which can be colored.
red
$("#container:contains('red')").each(function(){ $(this).html($(this).html().replace("red", "red")); });