Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

Double Link

Posted on 1998-10-27
5
Medium Priority
?
222 Views
Last Modified: 2010-04-09
I am the middle of making a page at the moment that uses frames. I have
a navigation frame and two others  and I would like to be able to make 1
link in the navigation frame open 2 different documents in the other two
frames. Is this possible? If so, how ?
0
Comment
Question by:Bishma
  • 3
  • 2
5 Comments
 
LVL 4

Expert Comment

by:martinag
ID: 1839088
<SCRIPT LANGUAGE="JavaScript">
<!--
function openFrames(a, b);
parent.FIRSTFRAME.location.href = a;
parent.SECONDFRAME.location.href = b;
// -->
</SCRIPT>
<A HREF="openFrames('page1.htm', 'page2.htm')">Link</A>

I guess you have named your frames:
<FRAME NAME="whatever" SRC="something.htm">

Martin
0
 

Author Comment

by:Bishma
ID: 1839089
This brings up an error cannot find "openFrames('chsr2.html','main.html')"
The documents exist in that directory.
I tryed adding "javascript:" to the front (ie "javascript:openFrames(....") and then it just told me that the document was done without doing anything.
The frames I am trying to change are named "stuff" and "main"

If you could elobrate a little it would help me out. I am a novice when it comkes to javascript.
0
 

Author Comment

by:Bishma
ID: 1839090
This brings up an error cannot find "openFrames('chsr2.html','main.html')"
The documents exist in that directory.
I tryed adding "javascript:" to the front (ie "javascript:openFrames(....") and then it just told me that the document was done without doing anything.
The frames I am trying to change are named "stuff" and "main"

If you could elobrate a little it would help me out. I am a novice when it comkes to javascript.
0
 
LVL 4

Accepted Solution

by:
martinag earned 400 total points
ID: 1839091
Ok, here it is. I forgot the {}'s. I've also changed your frame names.

<SCRIPT LANGUAGE="JavaScript">
<!--
function openFrames(a, b) {
  parent.stuffs.location.href = a;
  parent.main.location.href = b;
}
// -->
</SCRIPT>

And you're right about the "javascript:" I forgot that. The clock is running towards midnight at my side of the globe and I better go sleep.

Martin
0
 

Author Comment

by:Bishma
ID: 1839092
Worked like a charm.
0

Featured Post

Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Finding original email is quite difficult due to their duplicates. From this article, you will come to know why multiple duplicates of same emails appear and how to delete duplicate emails from Outlook securely and instantly while vital emails remai…
The first step to building an amazing About page is to figure out what you want the page to say about your company. You then must grab the attention of the reader, boast a bit, tell a story and let others brag about you. With a little bit of thought…
The viewer will receive an overview of the basics of CSS showing inline styles. In the head tags set up your style tags: (CODE) Reference the nav tag and set your properties.: (CODE) Set the reference for the UL element and styles for it to ensu…
Video by: Mark
This lesson goes over how to construct ordered and unordered lists and how to create hyperlinks.

824 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question