Change framset by javascript

H

hugoatkol

How to Resize a frameset without an id eg.

<frameset rows="85,*" framespacing="0" border="0" frameborder="NO">

<frame src="url1" name="dot_tk_frame_top" noresize scrolling="NO">
<frame src="url2" scrolling="auto" noresize>
</frameset>

sow thw rows change to eg. 75,* instead of 85,*
 
M

Martin Honnen

How to Resize a frameset without an id eg.

<frameset rows="85,*" framespacing="0" border="0" frameborder="NO">

<frame src="url1" name="dot_tk_frame_top" noresize scrolling="NO">
<frame src="url2" scrolling="auto" noresize>
</frameset>

sow thw rows change to eg. 75,* instead of 85,*

If you have a single not nested frameset then you can do e.g.
parent.document.body.rows = '75,*';

You can also use getElementsByTagName('frameset') and use a numerical
index e.g.
parent.document.getElementsByTagName('frameset')[0].rows = '75,*';
 
H

hugoatkol

How to Resize a frameset without an id eg.
<frameset rows="85,*" framespacing="0" border="0" frameborder="NO">
<frame src="url1" name="dot_tk_frame_top" noresize scrolling="NO">
<frame src="url2" scrolling="auto" noresize>
</frameset>
sow thw rows change to eg. 75,* instead of 85,*

If you have a single not nested frameset then you can do e.g.
parent.document.body.rows = '75,*';

You can also use getElementsByTagName('frameset') and use a numerical
index e.g.
parent.document.getElementsByTagName('frameset')[0].rows = '75,*';


I cna't get it ot work,

<frameset rows="85,*" framespacing="0" border="0" frameborder="NO">

<frame src="url1" name="name1" noresize scrolling="NO">
<frame src="url2" scrolling="auto" noresize>
</frameset>

the script is place i url2 i have jsut place the folowing script in
header

<script language="JavaScript" type="text/javascript">
parent.document.getElementsByTagName('frameset')[0].rows = '10,*'
</script>
 

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,780
Messages
2,569,608
Members
45,241
Latest member
Lisa1997

Latest Threads

Top