here comes the error
my verify file looks like:
<?php
$errors = array();
//READ the user recaptcha
require_once('recaptchalib.php');
$privatekey = "******************************";
$resp = recaptcha_check_answer ($privatekey,
$_SERVER["REMOTE_ADDR"],
$_POST["recaptcha_challenge_field"],
$_POST["recaptcha_response_field"]);
//READ the posted form data
$fromemail = $_POST['fromemail'];
$fname = $_POST['fname'];
$lname = $_POST['lname'];
$message = $_POST['message'];
//VALIDATE form data exists
if(!isset($frommail) ||
!isset($fname) ||
!isset($lname) ||
!isset($message)){
echo 'We are sorry, but there appears to be a problem with the form you submitted.';
}else{
echo 'success';
}
$fromemail = stripslashes($fromemail);
$fname = stripslashes($fname);
$lname= stripslashes($lname);
$message = stripslashes($message);
$fromemail = trim(htmlentities($fromemail));
$fname = trim(htmlentities($fname));
$lname= trim(htmlentities($lname));
$message = trim(htmlentities($message));
//VALIDATE !errors
if (!empty($errors)){
redirect_to("http://www.*******.com/index.php");
}
//CREATE the email form data
$to = "customerservice@*******.com";
$subject = $fname . " " . $lname;
$headers = "From: " . $fromemail;
if (!$resp) {
// What happens when the CAPTCHA was entered incorrectly
echo ("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 "SUCCESS!";
}
mail($to, $subject, $message, $headers);
?>