|
is_valid)
{
die ("The reCAPTCHA wasn't entered correctly. Go back and try it again." .
"(reCAPTCHA said: " . $resp->error . ")");
}
//////////// end of reCaptcha code /////////
//is already checked on the contact page but check to see if is a valid email format
if(!$userEmail == "" && (!strstr($userEmail,"@") || !strstr($userEmail,".")))
{
echo "Use Back - Enter valid e-mailn";
$badinput = "Inquiry was NOT submittedn";
echo $badinput;
die ();
}
//is already checked in contact.php as well but doesn't hurt to check again
if(empty($userName) || empty($userEmail) || empty($content ))
{
echo "Please go back and fill in all of the fieldsn";
die ();
}
$content = stripcslashes($content);
$message = 'Title: Link Exchange
URL: '.$url.'
Link Description: '.$linkDesc.'
Image URL: '.$imgURL.'
Category: '.$category.'
Recip. URL: '.$urlRecp.'
Name: '.$name.'
Email: '.$email;
$from = "From: $emailrn";
if(!mail($theEmail, $subject, $message, $from))
{
//Then there was a problem
echo 'There was a problem with the mailing function. Please try again.';
die();
}
?>
Your link exchange has been successfully submitted, thank you.
|
|