Hey guys,
I wanted to integrate reCaptcha in contact.php, but it doesn't work.
I uploaded recaptchalib.php to content/themes/Peafowl/pages so the captcha can work.
I noticed the $_POST (in contact.php) which is at the beginning of the file and the <form> in the end of it.
So I coded this for the form :
Where PublicKey = the publickey of my website and this for the data "recovery" :
Where PrivateKey = the privatekey of my website
The captcha loads but I still can send an e-mail without filling it, so I don't know...
If someone could help me, it would be cool !
I wanted to integrate reCaptcha in contact.php, but it doesn't work.
I uploaded recaptchalib.php to content/themes/Peafowl/pages so the captcha can work.
I noticed the $_POST (in contact.php) which is at the beginning of the file and the <form> in the end of it.
So I coded this for the form :
PHP:
require_once('recaptchalib.php');
$publickey = "PublicKey";
echo recaptcha_get_html($publickey);
PHP:
require_once('recaptchalib.php');
$privatekey = "PrivateKey";
$resp = recaptcha_check_answer (
$privatekey,
$_SERVER["REMOTE_ADDR"],
$_POST["recaptcha_challenge_field"],
$_POST["recaptcha_response_field"]
);
The captcha loads but I still can send an e-mail without filling it, so I don't know...
If someone could help me, it would be cool !