Work on a Wicket application that adds markup to the DOM after onLoad via the built-in AJAX Wicket to autocomplete the widget. We have IE6 crashes, which means I need to move the markup that goes into it, and I'm trying to avoid javascript Wicket interference ... blah blah blah ... this is what I'm trying to do:
- New markup arrives at the DOM (I don't have access to the callback)
- Somehow I know this, so I run my code.
I tried this, hoping that the new tags will trigger onLoad events:
$("selectorForNewMarkup").live("onLoad", function(){
});
... but got educated that onLoad only works when the page loads. Is there another event when elements are added to the DOM? Or another way to sense the changes in the DOM?
Anything I've run into similar problems with new markup additions, they have access to the callback function on .load () or the like, or they have a real javascript event to work and live () works fine.
Is this a dream dream?
source
share