iframe 100% height trickeration

L

laredotornado

Hi,
I am trying to get my iframe to occupy the entire height of the
table cell in which it is located. Sadly, this table cell may have
variable height. This is the code I'm using right now that doesn't
work on any browser ...

<tr>

<td><iframe style="background-color:#ffffff; border-style:none;
border-width:0px;" width="100%" height="300" src="features.php"
scrolling="auto"></iframe></td>
</tr>

Is there any JS trickery I can do to deduce the height fo that table
cell and then document.write the height attribute of the iframe? Even
if it only works on one browser, it would be better than nothing, which
is what I have now.

THanks, - Dave
 
W

web.dev

Hi,
I am trying to get my iframe to occupy the entire height of the
table cell in which it is located. Sadly, this table cell may have
variable height. This is the code I'm using right now that doesn't
work on any browser ...

<tr>

<td><iframe style="background-color:#ffffff; border-style:none;
border-width:0px;" width="100%" height="300" src="features.php"
scrolling="auto"></iframe></td>
</tr>

Just a thought and you don't indicate, but have you tried setting the
height of the iframe to 100%?
 
W

web.dev

Yes. I've yet to find a browser on which that works. -

I've tried the following on IE6 and it works for me:

<table>
<tr>
<td>
<iframe src = "path/page" style = "width: 100%; height: 100%"></iframe>
</td>
</tr>
</table>
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,995
Messages
2,570,230
Members
46,817
Latest member
DicWeils

Latest Threads

Top