My client needs an iframe on his page to load samples of his PHP scripts. He also wants it stretchable to any size if the window is not maximized. I haven't worked with iframes in years and would have no idea how to code them to stretch.
How would you code a stretchable iframe?
Started by UnderAttak, Mar 17 2007 03:40 AM
5 replies to this topic
#1
Posted 17 March 2007 - 03:40 AM
#2 _*Creative Insanity_*
Posted 17 March 2007 - 03:44 AM
I am not sure you can. They are normally a fixed pixel size.
#3
Posted 17 March 2007 - 04:08 AM
iFrames are terrible imo, php page includes are always better
stretchable too
stretchable too
#4
Posted 17 March 2007 - 12:15 PM
Iframes cannot be stretched by the user, but this question has been asked here before if you do a little searching, i believe faken was one of the people who finally solved the problem.
#5
Posted 18 March 2007 - 12:45 AM
Yeah I've been trying to convince them to not go with iframes. Apparently they sent me this site with a stretchable iframe. I haven't examined the code yet though.
http://www.mydump.in...me_stretch.html
Edit: looks like to me you can just use some CSS to code the iframe's width to 100% or whatever percentage you need.
http://www.mydump.in...me_stretch.html
Edit: looks like to me you can just use some CSS to code the iframe's width to 100% or whatever percentage you need.
Edited by UnderAttak, 18 March 2007 - 12:48 AM.
#6 _*Creative Insanity_*
Posted 18 March 2007 - 02:03 AM
Interesting.. but I still hate iframes.
#module {
border: 2px solid #8A8A8A;
width: 95%;
margin: 0px auto;
}
#module iframe {
display: block;
width: 100%;
height: 500px;
}
<div id="module"><iframe id="frame_module" name="frame_module" FRAMEBORDER=0 src="./modules/home.php"></iframe></div>
Edited by Creative Insanity, 18 March 2007 - 02:05 AM.
1 user(s) are reading this topic
0 members, 1 guests, 0 anonymous users
