views:

50

answers:

1

Hi All,

I really need someone's help on this> I have a little image inside an IFrame that upon being clicked on, will display another image and slide down a little. How can I make the IFrame automatically get bigger or smaller, according to its contents?

Thank you so much!

*edit After researching this more, I have found quite a few examples that claim (i have not tested them) to do what I need, but ONLY after a page-refresh. Which is something I cannot do.

+1  A: 

You can change the size of your iFrame using a JavaScript method. Then you associate that method to your iFrame's OnLoad event.

There was no point re-authoring the code as it is short and to the point in the above link. One person said it doesn't work in Opera but try it and see if it suits your needs.

François
Yeah, sorry Francois, the code from the link above really doesn't work. Thanks for trying though. :)
lucifer
Okay, after reading a lot more about IFrames, and scouring the web for a few weeks I was able to pick up a few things here and there, and apply it to the code sample demonstrated in the link you provided. So, thanks! :D
lucifer