From c05efa8d7ae464235cf83d7c0956e42dc6974103 Mon Sep 17 00:00:00 2001 From: julieng Date: Sat, 2 Oct 2021 17:20:14 +0200 Subject: move *.html to *.md --- .../windoweventhandlers/onbeforeunload/index.html | 49 ---------------------- 1 file changed, 49 deletions(-) delete mode 100644 files/fr/web/api/windoweventhandlers/onbeforeunload/index.html (limited to 'files/fr/web/api/windoweventhandlers/onbeforeunload/index.html') diff --git a/files/fr/web/api/windoweventhandlers/onbeforeunload/index.html b/files/fr/web/api/windoweventhandlers/onbeforeunload/index.html deleted file mode 100644 index 638f24c27b..0000000000 --- a/files/fr/web/api/windoweventhandlers/onbeforeunload/index.html +++ /dev/null @@ -1,49 +0,0 @@ ---- -title: window.onbeforeunload -slug: Web/API/WindowEventHandlers/onbeforeunload -translation_of: Web/API/WindowEventHandlers/onbeforeunload ---- -

Résumé

- -

Le gestionnaire d'événement WindowEventHandlers.onbeforeunload contient le code exécuté lorsque l'évènement {{event("beforeunload")}} est envoyé. Cet événement se déclenche lorsque la fenêtre est sur le point de recharger ses ressources.

- -

Syntaxe

- -
<element beforeunload="funcRef(event);" />
- -
<script type="text/javascript">
-	window.onbeforeunload = funcRef
-</script>
- - - -

Exemple

- -
window.onbeforeunload = function (e) {
-  var e = e || window.event;
-
-  // For IE and Firefox
-  if (e) {
-    e.returnValue = 'Any string';
-  }
-
-  // For Safari
-  return 'Any string';
-};
-
- -

Propriétés de l'objet event

- -
returnValue
- - - -

Spécification

- -

L'évènement 'onbeforeunload' a été introduit par Microsoft dans IE4 et s'est généralisé dans tous les navigateurs.

- -

MSDN—onbeforeunload Event

-- cgit v1.2.3-54-g00ecf