View Full Version : CSS menu that changes two frames.
Freeman
12-08-2006, 08:57 PM
I need a menu that changes two frames at once. The left frame will be navigation for the frame on the right. I looked in dynamic for a couple of hours but didn't find one that would work. Any help would be appreciated, JF
jscheuer1
12-13-2006, 06:43 AM
You're not giving us much to go on here. Sounds like you want a link that will load one page into one frame and another page into another frame. Menus are basically just organized and styled bunches of links so, the menu wouldn't matter so much as would the link though, to do this, different menus would probably need to be adapted in different ways. One way to target two different frames with one link is like so:
<a href="page1.htm" target="frameone" onclick="top.frames.frametwo.href='page2.htm';return true;">Link text</a>
Where frameone and frametwo are the names of the frames on the top page.
Then again, I may have completely missed your point.
Freeman
12-14-2006, 09:11 PM
onclick="top.frames.frametwo.href='page2.htm';return true;">Link text</a>
with the "top.frames.frametwo.href='page2.htm';return true;" is top.frames.frametwo.href supposed to go in just as it is and change the page that it is referencing?
jscheuer1
12-15-2006, 04:27 AM
frametwo is the name of the frame, if your frame has a different name, use it instead. The page can be whatever you like.
Freeman
01-16-2007, 08:37 PM
does this script work if it is in <li> tags?
Freeman
01-16-2007, 09:31 PM
<li><a href="about.htm" title="About School" target="main" onclick="top.frames.side.href='aboutside2.htm';return true;"><span>About School </span></a></li>
This is what I have. When you click on the link of the top frame it changes the main frame but not the side navigation frame. Is it a problem with this or a problem with the index?
<!-- Top navigation-->
<frameset rows="100, *">
<frame src="frame.htm" scrolling="no" noresize>
<!-- Side Navigation-->
<frameset cols="150, *">
<frame src="aboutside.htm" name="side" scrolling="no">
<!-- Main Page-->
<frameset cols="*, 0">
<frame src="home.htm" name="main">
This is the index. Something I am doing wrong? Thanks for any help, JF
jscheuer1
01-16-2007, 09:55 PM
Sorry, it needs to be location.href:
onclick="top.frames.side.location.href='aboutside2.htm';return true;"
Freeman
01-16-2007, 10:10 PM
I love you, Truly. Now I can build the navigation for my site. Thanks alot jscheuer1
Powered by vBulletin® Version 4.2.2 Copyright © 2021 vBulletin Solutions, Inc. All rights reserved.