[Javascript] window.close () not catched

Guillaume javascript at webdesignofficina.com
Mon Apr 24 09:15:12 CDT 2006


Hi list,

A new window is opened with an inline window.open JavaScript ( 
target="_blank"  refuses to pass Xhtml validation).
Trying to close this opened window with...

<a href="#" onclick="window.close()">Close</a>

... is working fine.

This new window offers the ability to browse images, previous / next 
links, one by one.
You can close the window any time, when any image is browsed...

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 ?

Any fix ?

Thank you for any help.

Guillaume.



More information about the Javascript mailing list