Please suggest possible techniques to trigger events in parent page from an iFrame. I tried out url Hashing and using window.postMessage techniques but without any success.
views:
121answers:
3
+1
A:
The only idea that comes to mind is to have a script on server side that the iFrame sends its events to (combined with a unique ID) and that the parent page can poll (either through a server script on its domain, or JSONP). That's a lot of work to do, though, and requires cooperation from both the parent page and the iframe.
Pekka
2010-05-05 08:01:42
A:
easyXDM is designed for this exact purpose. You can find it at http://easyxdm.net and it has quite a few examples.
To sum it up, it allows two windows to communicate 'freely' using either strings or RPC calls.
See http://consumer.easyxdm.net/current/example/methods.html for one of the RPC-demos.
Sean Kinsey
2010-05-05 09:49:00
By the way, feel free to contact me if you have an problems using it (I'm the author).
Sean Kinsey
2010-05-06 11:32:02