View Full Version : frames and such
zduck
09-23-2002, 07:52 PM
how can I make a javascript that will open a certain page in a defined frame when the onClick event is fired?
ASAAKI
09-23-2002, 08:28 PM
supposing u've got a frame like this:
<frame name="aframe" src="whatever.htm">
and this is the link that should activate a page being opened only in 'aframe', you'll do this:
<a href="yourlink.htm" target="aframe">
but if u want a link in a frame to open a page in the entire window and get rid of the frames, you do this:
<a href="yourlink.htm" target="top">, or maybe it's "_top", i'm forgetting...
beetle
09-23-2002, 08:37 PM
onClick="top.frames['frameName'].location.href='page.htm';"
where frameName is uh, the name of the frame :D
zduck
09-23-2002, 10:47 PM
thank you beetle. that is just what I needed.
-Zduck.com
vBulletin® v3.8.2, Copyright ©2000-2012, Jelsoft Enterprises Ltd.