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

Q970 How can I load an alien URL (i.e. a URL from another site) in one frame into the top window?

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

The _new_ security model in Netscape Navigator 4+ actually allows you to ask for extra privileges from the user to be able to do this. With the _old_ security model, you wouldn''t even have been able to ask.

<script language="JavaScript1.2"><!--
function doit() {
    if (document.layers) {
        netscape.security.PrivilegeManager.enablePrivilege('UniversalBrowserRead');
        top.location.href = parent.frames[1].history[parent.frames[1].history.length - 1];
    }
}
//--></script>

<a href="javascript:doit()">kill frame</a>

©2018 Martin Webb