Arthur Connor wrote in message ...
Below you will find the first lines of my HTML page.
Why doesn't popup a dialog window ?
I click the Html page which is on my hard disc. A IE 5.5 browser window
opensbut not a dialog window inside.
<HTML>
<HEAD>
<TITLE>Test page</TITLE>
<script LANGUAGE="JavaScript">
<!--
function popitup(percent){
popup = window.open("","popDialog","height=160,width=300,s crollbars=no");
popup.document.write("HELLO"+percent);
//popup.document.close();
}
// -->
<script>
</HEAD>
<BODY onLoad="popitup(0)">
....
Arty
<html>
<head>
<script language="JavaScript">
function popitup(percent) {
child_window = window.open
("","popDialog","width=300,height=160,left=0,top=0 ,menubar=0,toolbar=0,scrol
lbars=0") ;
child_window.document.write("HELLO" + percent) ;
child_window.document.close() ;
}
</script>
</head>
<body onLoad="popitup(0) ">
</body>
</html>
will open a popup from the main window with "HELLO0" as the content.
Alternatively:-
<html>
<head>
<script language="JavaScript">
var child_window = new Object ;
child_window.closed = true ;
function popclose() {
if (!child_window.closed) {
child_window.close() ;
}
}
function popup(args) {
if (!child_window.closed) {child_window.close() }
child_window =
window.open(args,"childwindow","toolbar=no,status= no,menubar=no,scrollbars=y
es,resizable=no,width=300,height=160,top=0,left=0" ) ;
}
</script>
</head>
<body onLoad="popup('myfile.html')" onUnload="popclose() ">
</body>
</html>
which will open a popup whose content is myfile.html that closes upon the
change of content of the parent (opener) window.
Hope that helps.
Jim
p.s. take a look at:-
http://www.paulspages.co.uk/pcp/151/menu151.htm