Frames

I have three frames in one html page. They are top ,left and the body pages.
The top page has menu tabs like menu1,
menu2 ,menu3 etc.
In the top.html page i have written a javascript so that when the user passes his mouse on each menu ie suppose he placesthe mouse on menu1 he wiuld get a dropdown box containing furtherlinks.Say ,if the mouse is kept on menu1 he would be shown link1,link2,link3.Similarly if mouse is placed on menu2 he would be shown some more links.

Now each of the links is a html page.
If the user clicks on link1 I want to dispaly the page keeping the top and left page as it is and only change the main page.

I would appreciate if i could get the javascript to do this.

Ramani
ramani081399Asked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

andrivCommented:
You can do this by adding <BASE TARGET="frame_name"> in the head section of the Link html page.  "frame_name"= the name of the widow you want the new page to open in.  The one you called body.
0
andrivCommented:
In the following example when ever someone clicks on one of the links (1,2 or 3) the html page which is being called will open in the frame labled body.

<html>
<head>
<title>Link page</title>
<base target="body">
</head>
<body>
<a href="1.html">1</a>
<a href="2.html">2</a>
<a href="3.html">3</a>
</body>
</html>
0
LermitteCommented:
No Java is need only set this:

< a href="Link 1.html" target="mainpage">

Wherre mainpage is the name that you have given to your main_page_Frame

Mario
0
Determine the Perfect Price for Your IT Services

Do you wonder if your IT business is truly profitable or if you should raise your prices? Learn how to calculate your overhead burden with our free interactive tool and use it to determine the right price for your IT services. Download your free eBook now!

andrivCommented:
Lermitte, <base> tag is not java but html.
0
LermitteCommented:
Ramani ask for java not you... so don't be affraid It was not to you.

Mario
0
ramani081399Author Commented:
Lermitte,

 Thanks for all your suggestions. I am sorry that I did not make my question clear. I would like to restate the problem.

 I have a page called homepage.html.
Thais is made up of three frames. top.html,left.htmland main.html.
The top.html has buttons button1,button2,button3 etc.
When the user keeps the mouse on the buttons  dropdown box appears with links in that box link1,link2,link3 etc.
(The drop down boxes wer created using the code given at the url http://www.webreference.com/dhtml/column21/exactly without altering anything in the code)

When I click on link1 from the dropdown box described I would like the only the main page to load and keep the top and left page as it is.

The problem that is happening is that when I click on link one the new mainpage pertaining to link one and the
homepage.html appear side by side on the browser and I am no longer able to see the effect of drop down box in the page that appears after clicking link1.

I am sorry that 30 points may be too small, I could increase it.Since ,this problem has beem troublesome , I posted this question.

Ramani
0
andrivCommented:
Both solutions suggested (lermitte and myself) should solve your problem. The <Base> tag will make any link open up in the frame name you enter.  Lermitte is doing exactly the same except you have to add target for each link.  If it doesn't work you should paste the frame.html and the code for the links so we can look at it and tell what is wrong with your code.
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
sureshkumarCommented:
ramani i am unable find that url. can you please send correct url
 
0
ramani081399Author Commented:
surehkumar,

 The url is
http://www.webreference.com/dhtml/column21

sorry about the type error after 21 exactly should not be there.
Ramani
0
morbiusxCommented:
in the link data it should be
a href="link1.html" target="main">link1</a>

0
jimmyontourCommented:
Just a suggestion;

Ramani, you seem to be using some very dangerous words (such as main, top, button, etc).
If you have used any of these words as your name variable in the frameset then you will have problems.
(e.g. <frame name="top" src="top.html">)
The inbuilt javascript machine in the browsers have reserved specially named variables for its own use.

If this is not the case, and you already knew this, then please don't be offended.

Another point:
Please post the source code from "webreference" in this comment list. It makes answering the question much much easier as the respondants can see exactly what is going on.

Good luck, Jimmyontour
0
ramani081399Author Commented:
Andriv,
 

 Jimmyontour,

 I solved the problem. I used the code gven at the URL
http://www.webreference.com/dhtml/column21 

Ramani
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
HTML

From novice to tech pro — start learning today.