all. I'm trying to create a widget that users can put on their site. I'm taking a page out of Facebook's book and let the users add using code like this crude example:
<script src="blah.js"></script>
<my:widget id="whatever"></my:widget>
This then creates a div containing an iframe inside of the tag.
Now, here's the tricky part. If a user clicks a button inside of this frame, it needs to expand the widget. So, I need to tell the div wrapping around the iframe to change its width and height. All I need to do is send a single flag up so blah.js can read it and do its thing. I tried adding an onload handler to the iframe and change to a different page, but the parent frame cannot read the current iframe's location.
When observing Facebook's like button behavior for liking pages (eg: ), I noticed that they insert an expanded frame into the DOM exactly like I want to do so that a user can add a comment. I just don't know how one manages to communicate to the other.
Any ideas?