Added invisible reCAPTCHA

This commit is contained in:
2017-10-30 16:09:46 +01:00
parent c6428d2251
commit e98421b807
2 changed files with 6 additions and 3 deletions

View File

@ -29,7 +29,7 @@ if($_POST) {
if (!$captcha){
$error['captcha'] = "Please check the CAPTCHA field.";
} else {
$captchaResponse = json_decode(file_get_contents("https://www.google.com/recaptcha/api/siteverify?secret=6Le1wRcTAAAAADbdnvPLKQ_hupTI4jzaGGXFQhQA&response=".$captcha."&remoteip=".$_SERVER['REMOTE_ADDR']), true);
$captchaResponse = json_decode(file_get_contents("https://www.google.com/recaptcha/api/siteverify?secret=6Le7VisUAAAAAKExpdr5NJy8AHGM0Y3iPI1eVZgD&response=".$captcha."&remoteip=".$_SERVER['REMOTE_ADDR']), true);
if($captchaResponse['success'] == false) {
$error['captcha'] = "You are a robot.";
}