[Javascript] window.close () not catched
David Dorward
david at dorward.me.uk
Mon Apr 24 09:19:14 CDT 2006
On Mon, Apr 24, 2006 at 04:15:12PM +0200, Guillaume wrote:
> A new window is opened with an inline window.open JavaScript (
> target="_blank" refuses to pass Xhtml validation).
Because you are using XHTML 1.0 Strict and it doesn't include a target
attribute?
> Except in Safari: this browser allows the window.close only when the
> window is opened first.
> If you browse to the second image inside this window the window.close
> does not work anymore...
>
> Any idea why ?
Presumably it ties the security to the document you open rather than
just the window, so a different document doesn't have the authority to
close the window.
> Any fix ?
Get rid of the JavaScript and decide user's already know how to close
windows - since they can do it for every other window on their system?
--
David Dorward http://dorward.me.uk
More information about the Javascript
mailing list