| Server IP : 210.245.233.93 / Your IP : 216.73.216.226 Web Server : Apache/2.2.15 (CentOS) System : Linux webserver2.onesolution.com.hk 2.6.32-754.35.1.el6.x86_64 #1 SMP Sat Nov 7 12:42:14 UTC 2020 x86_64 User : apache ( 48) PHP Version : 5.3.3 Disable Function : exec, shell_exec, system, passthru, popen, proc_open, pcntl_exec MySQL : ON | cURL : ON | WGET : ON | Perl : ON | Python : ON | Sudo : ON | Pkexec : ON Directory : /var/www/onesolution.com.hk/captcha/ |
Upload File : |
<?php
require_once('recaptchalib.php');
// domain name: global-key.onesolution.com.hk
// This is a global key. It will work across all domains.
// public key: 6LcVfNcSAAAAADl9pq4_6NeEC-1j4tUZrVOX_A9X
// private key: 6LcVfNcSAAAAAAd291tQqQA3dBBH5IV0OaY2tcgh (Use this when communicating between your server and our server. Be sure to keep it a secret.)
$privatekey = "6LcVfNcSAAAAAAd291tQqQA3dBBH5IV0OaY2tcgh";
$resp = recaptcha_check_answer ($privatekey,
$_SERVER["REMOTE_ADDR"],
$_POST["recaptcha_challenge_field"],
$_POST["recaptcha_response_field"]);
if (!$resp->is_valid) {
// What happens when the CAPTCHA was entered incorrectly
die ("The reCAPTCHA wasn't entered correctly. Go back and try it again." .
"(reCAPTCHA said: " . $resp->error . ")");
} else {
// Your code here to handle a successful verification
echo "true";
}
?>