Home Articles FAQs XREF Games Software Instant Books About Feedback Search Site-Map
irt.org logo

Q980 Is it possible to create an independent window that is always on top, but which doesn't interfere with the use of any other windows?

irt.org | Knowledge Base | JavaScript | Window | Q980 [ previous next ]

Q980 Is it possible to create an independent window that is always on top, but which doesn't interfere with the use of any other windows?

You don't seem to want a modal window - i.e. one that keeps on top and doesn't let you interact with other windows.

You can use a timer to bring the popup window to the top after a few seconds with:

<script language="JavaScript"><!--
var timer = '';
function blurred() {
    timer = setTimeout('self.focus()',5000);
}

function focused() {
    if (timer != '')
        clearTimeout(timer);
}
//--></script>

<body onBlur="blurred()" onFocus="focused()">

Or in Netscape Navigator 4+ you could request extra privileges from the user when creating a window so that it is always raised:

<script language="JavaScript1.2"><!--
if (document.layers) {
    netscape.security.PrivilegeManager.enablePrivilege('UniversalBrowserWrite');
}
var windowHandle = window.open('http://www.irt.org/','windowName','alwaysRasied=yes');
//--></script>

Provide feedback ...
AddThis Social Bookmark Button

Provide feedback ... AddThis Social Bookmark Button


Last Updated: 30th March 2008. Maintained by: Martin Webb and Michel Plungjan
irt.org liability, trademark, document use, privacy statement and software licensing rules apply.
Copyright © 1996-2008 irt.org, All Rights Reserved.