From 38362b591e64902d8071efcd9fe7c65a19e5501e Mon Sep 17 00:00:00 2001 From: KLuka Date: Sat, 14 Mar 2015 13:18:16 +0100 Subject: [PATCH] Better handling of Ctrl-W event * IE doesn't trigger warning when session is closed * IE and Firefox actually sends Ctrl-W event to terminal * In Chrome user still gets warning and event is NOT sent to terminal --- shellinabox/root_page.html | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/shellinabox/root_page.html b/shellinabox/root_page.html index c9614c2..a04ea21 100644 --- a/shellinabox/root_page.html +++ b/shellinabox/root_page.html @@ -105,9 +105,8 @@ window.onbeforeunload = function(e) { if (typeof window.shellinabox.session != "undefined") { return "Are you sure you want to leave this page?"; - } else { - return null; } + // Don't use explicit return } -->