mirror of
https://github.com/arnaucube/goCaptcha.git
synced 2026-02-06 19:16:44 +01:00
implemented security counter of IP answering incorrect to captcha, to ban the IP for some time
This commit is contained in:
@@ -1,4 +1,6 @@
|
||||
|
||||
#goCaptcha{
|
||||
max-width: 380px;
|
||||
}
|
||||
.c_blue300{
|
||||
background: #64B5F6!important;
|
||||
color: #ffffff!important;
|
||||
@@ -7,6 +9,10 @@
|
||||
background: #E57373!important;
|
||||
color: #ffffff!important;
|
||||
}
|
||||
.c_green300{
|
||||
background: #81C784!important;
|
||||
color: #ffffff!important;
|
||||
}
|
||||
.g_button{
|
||||
border: none;
|
||||
border-radius: 2px;
|
||||
@@ -31,8 +37,8 @@
|
||||
float: right;
|
||||
}
|
||||
.g_selected{
|
||||
border: 4px solid yellow;
|
||||
border: 5px solid #64B5F6;
|
||||
}
|
||||
.g_unselected{
|
||||
border: 4px solid white;
|
||||
border: 5px solid white;
|
||||
}
|
||||
|
||||
@@ -33,7 +33,7 @@ function showCaptcha(captcha) {
|
||||
html = "";
|
||||
html += "<h2>Select all " + captcha.question + "s</h2>";
|
||||
for (k in captcha.imgs) {
|
||||
html += "<img id='" + k + "' onclick='selectCaptchaImg(this)' src='" + goCaptchaURL + "/image/" + captcha.imgs[k] + "' style='width:150px;cursor:pointer;' />";
|
||||
html += "<img id='" + k + "' onclick='selectCaptchaImg(this)' src='" + goCaptchaURL + "/image/" + captcha.imgs[k] + "' style='width:120px;cursor:pointer;' class='g_unselected' />";
|
||||
}
|
||||
html += "<div onclick='validateCaptcha()' class='g_button c_blue300 g_floatRight'>Validate</div>";
|
||||
document.getElementById("goCaptcha").innerHTML = html;
|
||||
@@ -59,6 +59,7 @@ function validateCaptcha() {
|
||||
var html = "";
|
||||
if (resp) {
|
||||
html += "<h2>goCaptcha validated</h2>";
|
||||
html += "<div onclick='getCaptcha()' class='g_button c_green300 g_floatRight'>Reload Captcha</div>";
|
||||
} else {
|
||||
html += "<h2>goCaptcha failed</h2>";
|
||||
html += "<div onclick='getCaptcha()' class='g_button c_red300 g_floatRight'>Reload Captcha</div>";
|
||||
|
||||
@@ -13,14 +13,14 @@
|
||||
<br>
|
||||
<div class="container">
|
||||
<div class="row">
|
||||
<div class="col-sm-3"></div>
|
||||
<div class="col-sm-6">
|
||||
<div class="col-sm-4"></div>
|
||||
<div class="col-sm-5">
|
||||
<div class="panel panel-default">
|
||||
<div class="panel-heading c_blue300">
|
||||
<h3 class="panel-title">goCaptcha</h3>
|
||||
</div>
|
||||
<div class="panel-body">
|
||||
<div id="goCaptcha"></div>
|
||||
<div id="goCaptcha">Getting goCaptcha data from server</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user