Is it possible to include DOM events from a dynamically inserted QuickTime <object> in Internet Explorer

I have a specific question about a QuickTime instance in Internet Explorer.

QuickTime in IE uses the <object> as a behavior pattern to trigger DOM events. The <object> behavior refers from the QuickTime plugin instance to the IE behavior style: style = "behavior: url (#id_of_behavior_object)".

This works fine for all QuickTime <object> instances declared before window.onload, but QuickTime <object> instances inserted into the DOM after that do not accept DOM event behavior.

I don't know exactly how behaviors work and what I've read so far hasn't made me any wiser. Are the behaviors callable elements that reference them only on page load and therefore cannot be retrieved later?

Are there any methods for including DOM events from QuickTime objects inserted after the page has loaded?


Just so you know - I tried various DOM insertion methods - innerHTML, createElement and call iframes with its own html page containing the required objects. None of these work for triggering DOM events on insert after page load.

Hooray!

+2


source to share


2 answers


This question has been here for a while and I did quite a bit of hack to try and get it to work, but never found a way, so I must conclude that the answer is:



Not.

+1


source


What you need is a custom event triggered after your items have loaded. Obviously, the event handlers you assign during window.onload / document.ready / dom: loaded (whatever you call it - it depends on the library / framework) will not work, because the elements you are trying to use , do not exist yet.



If you are using any ajax call, just attach the observer method in the onSuccess handler.

0


source







All Articles