Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How do I like to a page and show the frame? 2

Status
Not open for further replies.

bboehle

Programmer
Aug 22, 2000
24
US
I have 2 sites site A needs to have a link to site B.. Both have frames.. There is a page within site B page.html. I put in <A HREF=&quot; TAREGET=&quot;_blank&quot;> This will bring up the page.html, which is fine and dandy but I need it to show the frame pat of site B.. What do I do to make a link open in a new window, show the page I want in the right frame and the left frame have the navigation.. (basically as you would see it if you were just on site B the whole time)?

Does that make sense?
 
If I'm thinking correctly, you need to insure that the frame names on both sites are the same and load the pages into the current frames?
Doing a double link will work:

<A HREF=&quot;#&quot;
onClick=&quot;parent.frame1name.location.href=site.htm&quot;;
onClick=&quot;parent.frame2name.location.href=site2.htm&quot;;>Link</A>

With this, the pages from the frames of site b will load into the frames of site a. You want the framenames to match so that when you click on the links from the nav menu, they load into the second frame and not a new window. Jonathan Hannan
Computer Repair, Webdesign
HTML, CGI, PERL, JavaScript, XML
 
I've been working with this and just not getting it. It seemed to do nothing.. so I right clicked the link and told it open in new window to see what it would load and it loaded the page that is already there :/

I changed it to look lie this

<A HREF=&quot;#&quot;
onClick=&quot;parent.left.location.href=onClick=&quot;parent.right.location.href=
And to

<A HREF=&quot;#&quot;
onClick=&quot;parent.left.onClick=&quot;parent.right.
Niether work.. I think i'm just not putting the information in correctly?
 
Try this:

<A HREF=&quot;page.html&quot;
onClick=&quot;parent.main.location='
In a table with two cells, the HREF will open the first page in frame 1 (Top or left) and the parent.main.location should load the second page in frame 2....(bottom or right). Jonathan Hannan
Computer Repair, Webdesign
HTML, CGI, PERL, JavaScript, XML
 
Well that was a little closer :)

When I put that in, it will now open that document the A HREF is pointing too inside the right frame. But I still don't get that documents corresponding frame for that site. :( It seems to completely ignore the onClick location.
 
WOOO that worked.. ok now next question :)

How do I change that code to make the new frame and new document open up in a new broswer window instead of using the current one?

THANKS TONS!

Brandon
 
which new frame and new document ???
anyway the function to call is window.open(...)
see m$ docs or netscrap docs for details ;-)
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top