faqts : Computers : Programming : Languages : JavaScript : Frames

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

65 of 115 people (57%) answered Yes
Recently 4 of 10 people (40%) answered Yes

Entry

HOW CAN I CHANGE THE IFRAME HEIGHT

Jul 14th, 2002 00:46
meng xianhui, nimrod eshed, http://colorweb.go.163.com


If in your Iframe Page,you can do it like this:
	parent.document.getElementById("mxhIframe").style.height = 
newValue
	parent.document.getElementById("mxhIframe").style.width = 
newValue
If you do it in the same page ,you can do  it  like :
<form name="oForm">
<input type=button value="Change height1" 
onclick="document.getElementById("mxhIframe").style.height = '200'">
<input type=button value="Change height2" 
onclick="document.getElementById("mxhIframe").height = '300'">
</form>
<iframe src="http://colorweb.go.163.com/indexold.html" 
id="mxhIframe"></iframe>