MDN’s new design is in Beta! A sneak peek: https://blog.mozilla.org/opendesign/mdns-new-design-beta/

GlobalEventHandlers.onclose

送至視窗的 close event 的處理器(handler)。(不支援 Firefox 2 及 Safari)

語法

window.onclose = funcRef;

參數

  • funcRef 為函式的參照。

範例

window.onclose = resetThatServerThing;

規範

規範 狀態 備註
WHATWG HTML Living Standard
The definition of 'onclose' in that specification.
Living Standard  

瀏覽器相容性

Feature Chrome Firefox (Gecko) Internet Explorer Opera Safari (WebKit)
Basic support (Yes) ? ? ? No support
Feature Android Android Webview Chrome for Android Firefox Mobile (Gecko) Firefox OS IE Mobile Opera Mobile Safari Mobile
Basic support ? (Yes) (Yes) ? ? ? ? No support

文件標籤與貢獻者

 此頁面的貢獻者: StanleyDing
 最近更新: StanleyDing,