Link to home
Start Free TrialLog in
Avatar of Pasqualis
Pasqualis

asked on

IFRAME height=100% ?

On the following page I'm trying to use an I frame:

http://www.tsjechie.net/board/view.php?pg=vakantiehuizen

The content of the IFRAME is this page: http://www.tsjechoreizen.nl/bookinn/ZoekSelectie.php?SoortVakantie=0

Hoe can I make the IFRAME height dynamic so it's always 100%?
Avatar of Michel Plungjan
Michel Plungjan
Flag of Denmark image

Avatar of Pasqualis
Pasqualis

ASKER

Thanks :(
<iframe id="iframeid1" src="http://www.yahoo.com"></iframe>

<script language="javascript">
function SetIFrameHeight(ifr1)
{
       if (ifr1) {
          if (document.all) {
            ifr1.height = ifr1.document.documentElement.offsetHeight;
      }
      else {
            ifr1.height = ifr1.offsetHeight;
      }
     }
}
//Usage
SetIFrameHeight ( document.getElementById('iframeId1') );
</script>


 
Thank you pravinasar!

Ok, so now in what part of my page to I place what ? :)
The link you posted

http://www.tsjechie.net/board/view.php?pg=vakantiehuizen

get redirected  to

http://www.tsjechie.net/board/view.php?pg=invalid_pg

So obviously I can not know the DOM structure.

From the link you posted, looks like you are dynamically generating the page.

A call to Javascript function I posted can be placed in your page at the end of page, after frame is loaded.

or

< body onload="">



Oh, I changed the name of the page ;-)

Please check here: http://www.tsjechie.net/board/view.php?pg=eurorelais
ASKER CERTIFIED SOLUTION
Avatar of Pravin Asar
Pravin Asar
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial