View Full Version : Expandable iFrame Problemo...
Recursion
08-06-2007, 07:53 PM
Hello,
How would I make it so the DIV the iFrame was in would expand downwards with the iFrame?
;; Tom
Moved by opensourcehost (Forum Moderator) from Web Designing: Please post in the correct forum next time, thanks http://habboxforum.com/images/smilies/smile.gif.
Iframes do not expand!
In this case you'd either have to use a JS hack which risks working in only some browsers or use PHP Includes (more user friendly)
:Liam
08-06-2007, 08:05 PM
so you want the div with the iframe in to expand?
This is my way:
<html><head> <style type="text/css"> #DIVIDHERE {width:100px; height: 100px; margin-left: 000px; background-image: url(urlhere);} </head>
<body><div id="DIVIDHERE">expanding iframe code here.</div> </body> </html> I set a width so that the iframe wouldnt flow out and set a height so there is a default height when the content box is empty.
@above. That won't work..
:Liam
08-06-2007, 08:07 PM
@above. That won't work..
I use this all the time, it does. this code only expands downwards, if you wanted it to expand across you would remove the width code, but he may want a basic width for the content div so I added a width just in case and so that there is a basic height and width when the content box is empty.
Aflux
08-06-2007, 08:09 PM
Myke, with JS, iFrames do expand.
Sygon..
08-06-2007, 08:14 PM
iFrames suck bad in most browsers, firefox, ie6-7 alot of security holes.
Recursion
08-06-2007, 08:58 PM
iFrames suck bad in most browsers, firefox, ie6-7 alot of security holes.
I wanted to use PHP Include, but it broke my layout :|
Myke, with JS, iFrames do expand.
I said that ^_^
here ;]
http://www.dynamicdrive.com/dynamicindex17/iframessi2.htm
Heinous
09-06-2007, 01:55 AM
Myke, with JS, iFrames do expand.
Javascript manipulates the document. It could be any element, it's not an expanding iframe, it's a javascript hack.
Want to hide these adverts? Register an account for free!
Powered by vBulletin® Version 4.2.5 Copyright © 2024 vBulletin Solutions Inc. All rights reserved.