搜尋 Mozilla 技術支援網站

防止技術支援詐騙。我們絕對不會要求您撥打電話或發送簡訊,或是提供個人資訊。請用「回報濫用」功能回報可疑的行為。

Learn More

window.close

  • 無回覆
  • 1 有這個問題
  • 4 次檢視
more options

Hello,

we've got a problem with the window.close() function and the postback on a tab. When we open the new tab with a js function, the js window.close() works normally. But if this tab is refreshed, by a postback on button (this is an asp.net web application), firefox loses the information regarding the fact that the tab was opened via script and gives this error : "scripts may not close windows that were not opened by script". But this page was opened by a script. Why firefox loose this information??


thanks in advance, Emanuele

Hello, we've got a problem with the window.close() function and the postback on a tab. When we open the new tab with a js function, the js window.close() works normally. But if this tab is refreshed, by a postback on button (this is an asp.net web application), firefox loses the information regarding the fact that the tab was opened via script and gives this error : "scripts may not close windows that were not opened by script". But this page was opened by a script. Why firefox loose this information?? thanks in advance, Emanuele