Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people, just like you, are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
Solved

frame menu

Posted on 1997-03-25
3
203 Views
Last Modified: 2013-12-25
In my main file, I open a window menu with Javascript (window.open command). This new window menu contains several links which should load different documents to the "parent" URL. I have tried to refer to the parent document as "parent", or "top", but it won't work. Tell me how can I refer to the caller-parent document from the window opened in Javascript?
0
Comment
Question by:apero
3 Comments
 
LVL 1

Expert Comment

by:Michel021497
ID: 1854017
You must give eeach frame a name. For example:
<FRAME SRC=main.html NAME=main>

When you want a document to load in main.html, you can use TARGET=main.

FOR EXAMPLE <A HREF=doc1.html TARGET=main>Document 1</A>

This loads doc1.html in the frame where main.html was loaded.
0
 

Author Comment

by:apero
ID: 1854018
THere are noframes whatsoever,
If there were frames,
I would have no problems with it, but there AREN'T
I just want to control a non-framed document
from a flying menu, which is opened from the current
 docume.Any other suggestions?
0
 
LVL 4

Accepted Solution

by:
jshamlin earned 50 total points
ID: 1854019
HTML "TARGET" syntax addresses defines frames named in the HTML <FRAMESET> - since the new window was defined by Javascript, the window's name is not available to HTML "TARGET" values.

And so, you can *only* access the window by name in JavaScript.  This can most cleanly be done using document.open, thus:

   window_name.document.open("text/html","replace")

If I'm reading you right - you've created a child window from the main browser window, so the main browser window isn't explicitly named.  No problem - it's the parent - so use ...

   parent.document.open("text/html","replace")
0

Featured Post

Webinar: Aligning, Automating, Winning

Join Dan Russo, Senior Manager of Operations Intelligence, for an in-depth discussion on how Dealertrack, leading provider of integrated digital solutions for the automotive industry, transformed their DevOps processes to increase collaboration and move with greater velocity.

Question has a verified solution.

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

Boost your ability to deliver ambitious and competitive web apps by choosing the right JavaScript framework to best suit your project’s needs.
FAQ pages provide a simple way for you to supply and for customers to find answers to the most common questions about your company. Here are six reasons why your company website should have a FAQ page
This tutorial walks through the best practices in adding a local business to Google Maps including how to properly search for duplicates, marker placement, and inputing business details. Login to your Google Account, then search for "Google Mapmaker…
The viewer will learn how to look for a specific file type in a local or remote server directory using PHP.

856 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