aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorClaude <longneck@scratchbook.ch>2017-09-29 10:31:06 +0200
committerClaude <longneck@scratchbook.ch>2017-09-29 10:31:06 +0200
commit09fb70092320fb88f90fb5511f43d79161fd4878 (patch)
treed7e6fab39b47634b3be7d86a9d0f21c989af8b88
parent04907662738ee62c7ae26689f5534d23cbb20572 (diff)
downloadstikked-fit-09fb70092320fb88f90fb5511f43d79161fd4878.tar.gz
stikked-fit-09fb70092320fb88f90fb5511f43d79161fd4878.tar.bz2
stikked-fit-09fb70092320fb88f90fb5511f43d79161fd4878.zip
captcha js for bootstrap as well
-rw-r--r--htdocs/themes/bootstrap/js/stikked.js6
1 files changed, 4 insertions, 2 deletions
diff --git a/htdocs/themes/bootstrap/js/stikked.js b/htdocs/themes/bootstrap/js/stikked.js
index 8db956c..edec093 100644
--- a/htdocs/themes/bootstrap/js/stikked.js
+++ b/htdocs/themes/bootstrap/js/stikked.js
@@ -144,11 +144,13 @@ ST.crypto = function() {
'code': encrypted,
'lang': $('#lang').val(),
'expire': $('#expire').val(),
+ 'captcha': $('#captcha').val(),
'reply': $('input[name=reply]').val()
},
function(redirect_url) {
- if (redirect_url.indexOf('invalid') > -1) {
- $('#create_encrypted').parent().html('<p>' + redirect_url + '#' + key + '</p>');
+ if (redirect_url.indexOf('E_CAPTCHA') > -1) {
+ $('.container .message').remove();
+ $('.container:eq(1)').prepend('<div class="message error"><div class="container">The captcha is incorrect.</div></div>');
} else {
window.location.href = base_url + redirect_url + '#' + key;
}

© 2014-2024 Faster IT GmbH | imprint | privacy policy