Hi all,
On my website I have an iframe that displays content according to what the visitor clicks on. However, let's say that the user clicks on a page that has lots of text. I've coded the frame so that it automatically adjusts its height to fit the content via a simple javascript. However, the problem is that when he/she clicks on a link that displays a smaller amount of text (in the iframe) after viewing a lot of text, the iframe doesn't update its height. This produces a rather awkward layout, where there is little text, and an unnecessary amount of space below. I noticed that when I refresh the page, the javascript straightens itself out, and the iframe properly adjusts to its content.
How can I fix this?
Thanks
On my website I have an iframe that displays content according to what the visitor clicks on. However, let's say that the user clicks on a page that has lots of text. I've coded the frame so that it automatically adjusts its height to fit the content via a simple javascript. However, the problem is that when he/she clicks on a link that displays a smaller amount of text (in the iframe) after viewing a lot of text, the iframe doesn't update its height. This produces a rather awkward layout, where there is little text, and an unnecessary amount of space below. I noticed that when I refresh the page, the javascript straightens itself out, and the iframe properly adjusts to its content.
How can I fix this?
Thanks