check($_POST['captcha_code']) == false) { // the code was incorrect // handle the error accordingly with your other error checking // or you can do something really basic like this $submitted = 'no'; } else { //Captcha Code $ip = @$_SERVER['REMOTE_ADDR']; $Full_Name = $_POST['Full_Name']; $Street = $_POST['Street']; $City = $_POST['City']; $State = $_POST['State']; $Zip = $_POST['Zip']; $Home_Phone = $_POST['Home_Phone']; $Work_Phone = $_POST['Work_Phone']; $Email = $_POST['Email']; $Contact_Method = $_POST['Contact_Method']; $Comments = $_POST['Comments']; $msg=""; if($ip){ $msg .= "IP Address: \t $ip \n"; } if($Full_Name){ $msg .= "Full Name: \t $Full_Name \n"; } if($Street){ $msg .= "Street: \t $Street \n"; } if($City){ $msg .= "City/Country: \t $City \n"; } if($State){ $msg .= "State: \t $State \n"; } if($Zip){ $msg .= "Zip Code: \t $Zip \n"; } if($Home_Phone){ $msg .= "Home Phone: \t $Home_Phone \n"; } if($Work_Phone){ $msg .= "Work Phone: \t $Work_Phone \n"; } if($Email){ $msg .= "Email: \t $Email \n"; } if($Contact_Method){ $msg .= "Contact Method: \t $Contact_Method \n"; } if($Comments){ $msg .= "Comments: \t $Comments \n"; } $sender_name = $Full_Name; $sender_email = $Email; $mailheaders = "MIME-Version: 1.0\r\n"; $mailheaders .= "Content-type: text/plain; charset=iso-8859-1\r\n"; $mailheaders .= "From: $sender_name\r\n"; $mailheaders .= "Reply-To: $sender_email\r\n"; mail("webmaster@haymeadows.com","Information Request from thesocialsecurityadvisor.com",stripslashes($msg), $mailheaders); mail("info@thesocialsecurityadvisor.com","Information Request from thesocialsecurityadvisor.com",stripslashes($msg), $mailheaders); $submitted = 'yes'; } } ?>
|