Home Articles FAQs XREF Games Software Instant Books BBS About FOLDOC RFCs Feedback Sitemap

Q728 How do I change the location of another frame?

You are here: irt.org | FAQ | JavaScript | Frame | Q728 [ previous next ]

Instead of using something like:

location.href = 'apage.htm';

use one of the following:

parent.framename.location.href = 'apage.htm';
top.framename.location.href = 'apage.htm';
parent.frames[1].location.href = 'apage.htm';
top.frames[1].location.href = 'apage.htm';

where 0 is the first frame in the frameset, 1 is the second frame, 2 is the third frame.

©2018 Martin Webb