You should do this via an AJAX call to the server, providing the highlight keyword string and returning the divs, something like this:
$("#content").load('page.aspx', {'keywords':$('#searchBox').val()});
In this approach your server would return only the divs (with highlighting!) based on the passed keywords
string, and this would populate the <div id="content">
with them.
The highlighting on the client is cheap, but searching for what to highlight is extremely expensive in javascript, that's a lot of DOM crawling going on. Doing this via the server on a timeout would be the best approach, so it doesn't do it as they're typing every keystroke, something like this:
$('#searchBox').unbind('keyup').keyup(function() {
clearTimeout($.data(this, 'timer'));
var wait = setTimeout(function() {
$("#content").load('page.aspx', {'keywords':$('#searchBox').val()});
}, 150);
$(this).data('timer', wait);
});
This would perform a server callback, but only 150ms after the user stops typing. I find this a comfortable interval, but adjust as needed...or bind the function directly to the click
event of something...whatever best suits your interface :)