You can use jQuery methods for highlighting specific words in free text.
The most sophisticated way to solve the problem was the use of a regular expression. Every appearance of the searchword will be surrounded with an span tag.
$('p:contains('+str+')').
each(function(){
var regex = new RegExp(str, "g");
$(this).html($(this).html().replace( regex ,""+str+""));
});