开发者

Placing a web application in a web page without using an iFrame?

开发者 https://www.devze.com 2023-01-29 09:54 出处:网络
I have a website and 开发者_Python百科I need to place a web application inside one of its pages. The web application obviously has many pages and they are of varying heights. I was thinking of placing

I have a website and 开发者_Python百科I need to place a web application inside one of its pages. The web application obviously has many pages and they are of varying heights. I was thinking of placing it inside an iFrame. However, with an iFrame, I have the auto height problem. Since the links change within the iFrame itself, it is more difficult to adjust its height, since only the contents inside the iFrame itself will be changing and not the actual page itself (i.e. the URL).

Is there a more clever and cleaner way how I can implement this without using an iFrame.

I also tried using ssi includes but for some reason, they are working everywhere else but when I place the application inside an include, it won't work.

Many thanks


Put this in the onLoad of the iframe:

parent.document.getElementById('the-iframe-id').height = document['body'].offsetHeight;
0

精彩评论

暂无评论...
验证码 换一张
取 消