Simply When you open new windows assing it to variables.
<script language=javascript type=text/javascript>
var win1;
var win2;
var win3;
function openNewWindow()
{
win1 = window.open("page1.aspx");
win2 = window.open("page1.aspx");
}
function CloseChildren()
{
win1.close();
...........
}
then in body onunload event call CloseChildren()
Note: each new window must assign to diffrent variable then check them all
if not null (NaN) They close it..
Ask a Question
Want to reply to this thread or ask your own question?
You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.