From a9c98a1177f7491f59765ce7a24583083a04c148 Mon Sep 17 00:00:00 2001 From: "Matteo Nastasi (mop)" Date: Sat, 22 Nov 2008 10:46:31 +0000 Subject: [PATCH] unmediated logout refactored --- web/briskin5/Obj/briskin5.phh | 2 +- web/briskin5/index_rd.php | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/web/briskin5/Obj/briskin5.phh b/web/briskin5/Obj/briskin5.phh index c1c0f5b..904e1bf 100644 --- a/web/briskin5/Obj/briskin5.phh +++ b/web/briskin5/Obj/briskin5.phh @@ -408,7 +408,7 @@ class Briskin5 { $user_cur->laccwr = $curtime; $ret = "gst.st = ".($user_cur->step+1)."; "; - $ret .= 'gst.st_loc++; the_end=true; window.onunload = null; document.location.assign("../index.php");|'; + $ret .= 'gst.st_loc++; the_end=true; window.onbeforeunload = null; window.onunload = null; document.location.assign("../index.php");|'; log_wr($user_cur->sess." BRISKIN5_WAKEUP: ".$ret); $user_cur->comm[$user_cur->step % COMM_N] = $ret; diff --git a/web/briskin5/index_rd.php b/web/briskin5/index_rd.php index 8c9576d..5078362 100644 --- a/web/briskin5/index_rd.php +++ b/web/briskin5/index_rd.php @@ -58,7 +58,7 @@ function unrecerror() $is_page_streaming = TRUE; log_rd2("UNREC_ERROR"); - return (sprintf('the_end=true; window.onunload = null; document.location.assign("../index.php");')); + return (sprintf('the_end=true; window.onbeforeunload = null; window.onunload = null; document.location.assign("../index.php");')); } function page_sync($sess, $page) @@ -67,7 +67,7 @@ function page_sync($sess, $page) $is_page_streaming = TRUE; log_rd2("PAGE_SYNC"); - return (sprintf('the_end=true; window.onunload = null; document.location.assign("%s");', $page)); + return (sprintf('the_end=true; window.onbeforeunload = null; window.onunload = null; document.location.assign("%s");', $page)); } -- 2.17.1