Hi, in my setup [1], "load" is fired, but your handler will not work as expected because of the security restrictions imposed by the browser. For instance, iframe.getBody() returns null.
In Chrome, the developer console reports: "Unsafe JavaScript attempt to access frame with URL http://qooxdoo.org/". Tristan [1] Pasted your code into the playground. Ran on localhost and demo.qooxdoo.org. Am 05.06.2011 um 00:07 schrieb mrakus1: > CODE: > var pane = new qx.ui.splitpane.Pane("horizontal"); > > var tree = new qx.ui.tree.Tree(); > tree.setDecorator(null); > > var root = new qx.ui.tree.TreeFolder("/"); > root.setOpen(true); > tree.setRoot(root); > > var url = "http://www.qooxdoo.org"; > var iframe = new qx.ui.embed.Iframe().set({ > source: url, > scrollbar : "no", > decorator : null > }); > iframe.setAppearance("widget"); > > iframe.addListenerOnce( > "load", > function(e) > { > // var body = iframe.getBody(); > // body.innerHTML = "Test"; > var doc = iframe.getDocument(); > var _navi = doc.getElementById("navigation"); > qx.event.Registration.addListener(_navi, "click", function() { > doc.body.innerHTML = "test"; > }, this); > } > ); > > pane.add(tree, 0); > pane.add(iframe, 1); > this.getRoot().add(pane, {edge : 0}); > > Hello. > > Please help. I try to set addListener to iframe html code, but event not > work. What i do wrong? > Thanks. > > -- > View this message in context: > http://qooxdoo.678.n2.nabble.com/Manage-events-on-Iframe-tp6440372p6440372.html > Sent from the qooxdoo mailing list archive at Nabble.com. > > ------------------------------------------------------------------------------ > Simplify data backup and recovery for your virtual environment with vRanger. > Installation's a snap, and flexible recovery options mean your data is safe, > secure and there when you need it. Discover what all the cheering's about. > Get your free trial download today. > http://p.sf.net/sfu/quest-dev2dev2 > _______________________________________________ > qooxdoo-devel mailing list > [email protected] > https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel ------------------------------------------------------------------------------ EditLive Enterprise is the world's most technically advanced content authoring tool. Experience the power of Track Changes, Inline Image Editing and ensure content is compliant with Accessibility Checking. http://p.sf.net/sfu/ephox-dev2dev _______________________________________________ qooxdoo-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel
