diff options
Diffstat (limited to 'extensions/BrowserID/template/en/default/hook')
2 files changed, 8 insertions, 10 deletions
diff --git a/extensions/BrowserID/template/en/default/hook/account/auth/login-additional_methods.html.tmpl b/extensions/BrowserID/template/en/default/hook/account/auth/login-additional_methods.html.tmpl index 4d8d8d3f0..590efdfb3 100644 --- a/extensions/BrowserID/template/en/default/hook/account/auth/login-additional_methods.html.tmpl +++ b/extensions/BrowserID/template/en/default/hook/account/auth/login-additional_methods.html.tmpl @@ -7,10 +7,9 @@ function browserid_sign_in() { if (assertion) { // This code will be invoked once the user has successfully // selected an email address they control to sign in with. - window.location.href = "[% target FILTER none %]index.cgi?browserid_assertion=" + assertion; - } else { - // something went wrong! the user isn't logged in. - alert("Oh no! Something went wrong..."); + var token = "[% issue_hash_token(['login']) FILTER html %]"; + window.location.href = "[% login_target FILTER none %]?token=" + + token + "&browserid_assertion=" + assertion; } }); } @@ -20,4 +19,4 @@ function browserid_sign_in() { Or, you could login using BrowserID: <img src="extensions/BrowserID/web/sign_in_orange.png" onclick="browserid_sign_in()"> </p> -[% END %]
\ No newline at end of file +[% END %] diff --git a/extensions/BrowserID/template/en/default/hook/account/auth/login-small-additional_methods.html.tmpl b/extensions/BrowserID/template/en/default/hook/account/auth/login-small-additional_methods.html.tmpl index 12bff015b..9871d585d 100644 --- a/extensions/BrowserID/template/en/default/hook/account/auth/login-small-additional_methods.html.tmpl +++ b/extensions/BrowserID/template/en/default/hook/account/auth/login-small-additional_methods.html.tmpl @@ -7,14 +7,13 @@ function browserid_sign_in() { if (assertion) { // This code will be invoked once the user has successfully // selected an email address they control to sign in with. - window.location.href = "[% login_target FILTER none %]?browserid_assertion=" + assertion; - } else { - // something went wrong! the user isn't logged in. - alert("Oh no! Something went wrong..."); + var token = "[% issue_hash_token(['login']) FILTER html %]"; + window.location.href = "[% login_target FILTER none %]?token=" + + token + "&browserid_assertion=" + assertion; } }); } </script> <img src="extensions/BrowserID/web/sign_in_orange.png" onclick="browserid_sign_in()" style="margin-bottom: -8px"> or -[% END %]
\ No newline at end of file +[% END %] |