I use the script below to open a side panel on my desktop without all the
buttons and menu items. IE 6
It works well.
What I'd like to add is add a line of code that will close the calling
parent window (right now I make it visible by resizing it and clicking on a
close link). I'll even settle for having to confirm the closure but, the
ultimate would be that it would close by itself.
KD
=============== =============== ==
<html>
<title>MySideBa r</title>
<body bgcolor="#FFFFF F" onLoad="OpenSid eBar()">
<script language="JavaS cript">
<!--
// This function moves the window when the page is loaded
// to the top left corner and resizes it then opens a side window panel
// ideally I want it to close the calling browser window, even if asked to
confirm
//
function OpenSideBar()
{
self.moveTo(0,0 )
self.resizeTo(3 00,300)
window.open("ht tp://www.google.ca", "MySideBar","wi dth=150,height= 965,left=0,
top=0,location= no,menubar=no,r esizable=no,scr ollbars=yes,sta tus=no,toolbar= n
o,fullscreen=no ")
}
function CloseWindow()
{
self.close()
}
-->
</script>
<div align="right">
<table border="0">
<tr>
<td><a href=javascript :CloseWindow()> Close Window</a>
</tr>
</table>
</div>
</body>
</html>
buttons and menu items. IE 6
It works well.
What I'd like to add is add a line of code that will close the calling
parent window (right now I make it visible by resizing it and clicking on a
close link). I'll even settle for having to confirm the closure but, the
ultimate would be that it would close by itself.
KD
=============== =============== ==
<html>
<title>MySideBa r</title>
<body bgcolor="#FFFFF F" onLoad="OpenSid eBar()">
<script language="JavaS cript">
<!--
// This function moves the window when the page is loaded
// to the top left corner and resizes it then opens a side window panel
// ideally I want it to close the calling browser window, even if asked to
confirm
//
function OpenSideBar()
{
self.moveTo(0,0 )
self.resizeTo(3 00,300)
window.open("ht tp://www.google.ca", "MySideBar","wi dth=150,height= 965,left=0,
top=0,location= no,menubar=no,r esizable=no,scr ollbars=yes,sta tus=no,toolbar= n
o,fullscreen=no ")
}
function CloseWindow()
{
self.close()
}
-->
</script>
<div align="right">
<table border="0">
<tr>
<td><a href=javascript :CloseWindow()> Close Window</a>
</tr>
</table>
</div>
</body>
</html>
Comment