Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

onBlur window close

Status
Not open for further replies.

Izzo

Technical User
Feb 22, 2001
38
US
Hi All,

In a popup I have <body onBlur=self.close()>

Works fine but what's happening is if I click into a table on that page the
focus goes to the table therefore blurring the body and closing the window.


I'm trying to make an else/if script that will ignore the table focus or
else close the window if blurred any other way. I don't know how to go about this. Can anyone help?

I'm thinking of giving the table an id and accessing it this way?

Kind of what I want to happen:

function Close(id) {
document.getElementById(id);
}

if (document.obj[id]) {
focused then don't close
} else {
closeon blur
}

Thanks, Jenny
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top