If you arent planning on supporting IE you can use DOMNodeInserted and DOMNodeRemoved to check if elements are added or removed from your div.
$('#yourDiv').bind('DOMNodeInserted DOMNodeRemoved', function(event, oldvalue, newvalue) {
if (oldval != newval){
return true;
}
return false;
});
for IE support you can use
$(function() {
var $div = $("#yourDiv");
var content = $div.html();
var look = setInterval(function() {
var newcontent = $div.html();
if (html != newcontent ) {
change(content, newcontent);
content = newcontent;
}
},100);
function change(oldval, newval() {
if (oldval != newval){
return true;
}
return false;
}
});