Home Articles FAQs XREF Games Software Instant Books BBS About FOLDOC RFCs Feedback Sitemap
irt.Org
#

Q417 How do I link from the main window to a named link within a frame within a pop up window?

You are here: irt.org | FAQ | JavaScript | Window | Q417 [ previous next ]

In the main window:

<script language="JavaScript"><!--
windowReference = window.open('page.htm','windowName','width=200,height=200');

function jump() {
    windowReference.frameName.location.href = 'page1.htm#anchorName';
}
//--></script>

<a href="javascript:jump()">link text</a>

In page.htm:

<frameset rows="50%,*">
<frame src="page1.htm" name="frameName">
<frame src="about:blank">
</frameset>

In page1.htm:

<p>A paragraph
<p>A paragraph

<a name="anchorName"></a>

<p>Anchor point

<p>A paragraph
<p>A paragraph

Feedback on 'Q417 How do I link from the main window to a named link within a frame within a pop up window?'

©2018 Martin Webb