From: Art Cancro Date: Wed, 5 Jan 2011 03:58:55 +0000 (-0500) Subject: Applied the GetLoggedInFirst() semantics to the Reply buttons X-Git-Tag: v8.11~933 X-Git-Url: https://code.citadel.org/?p=citadel.git;a=commitdiff_plain;h=77f362e0ff4d70dcb1f1881489b8fdbff4097611 Applied the GetLoggedInFirst() semantics to the Reply buttons --- diff --git a/webcit/static/authmethods.js b/webcit/static/authmethods.js index 3709669d0..1fc45a03c 100644 --- a/webcit/static/authmethods.js +++ b/webcit/static/authmethods.js @@ -27,7 +27,7 @@ function GetLoggedInFirst(destination_url) { /* If logged in already, go directly to the destination. */ if (IsLoggedIn()) { - window.location = destination_url; + window.location = decodeURIComponent(destination_url); return; } @@ -50,11 +50,12 @@ function GetLoggedInFirst(destination_url) { * Attempt login with username/password, called from modal dialog */ function ajax_try_username_and_password(destination_url) { + $('login_errmsg').innerHTML = ""; $('ajax_username_password_form').request({ onSuccess: function(ctdlresult) { if (ctdlresult.responseText.substr(0,1) == '2') { - window.location = destination_url; + window.location = decodeURIComponent(destination_url); } else { $('login_errmsg').innerHTML = ctdlresult.responseText.substr(4) ; diff --git a/webcit/static/t/get_logged_in.html b/webcit/static/t/get_logged_in.html index 40124ea57..92540c2dd 100644 --- a/webcit/static/t/get_logged_in.html +++ b/webcit/static/t/get_logged_in.html @@ -45,7 +45,7 @@ FIXME login to continue
-
');">
+
');">