faqts : Computers : Programming : Languages : JavaScript

+ Search
Add Entry AlertManage Folder Edit Entry Add page to http://del.icio.us/
Did You Find This Entry Useful?

8 of 66 people (12%) answered Yes
Recently 2 of 10 people (20%) answered Yes

Entry

How can i resize an iframe to match the width and height of the page it contains?

Apr 7th, 2008 23:27
ha mo, Colin Fraser, Tec-Nico, Pieter Smit,


I just read the question, and it does not make a lot of sense. Sorry,
but the way the question reads is that you want to make sure that an
iframe matches the size of the page going into it?
If I read this right then I can safely say, never gunna happen. 
Pages are written to conform to the space avaiable to them, not the
other way around. However, you can turn small pages, very small pages
into images and place them into iframes. However, I will also guarrantee
that will fail, sooner or later. You can always create an iframe to the
maximum space available to it, using its own attributes, dynamically set
by a javascript as the window opens. Code should be easy enough using
screen.width and scree.height and/or window.innerwidth and
window.innerheight. 
good luck.
http://www.businessian.com
http://www.computerstan.com
http://www.financestan.com
http://www.healthstan.com
http://www.internetstan.com
http://www.moneyenews.com
http://www.technologystan.com
http://www.zobab.com
http://www.healthinhealth.com