if( $_POST['submit'] == "Submit" ) { session_start(); if( $_SESSION['security_code'] == $_POST['security_code'] && $_POST['Name'] && $_POST['eMail'] && $_POST['Subject'] && $_POST['Message'] ) { // DESTINATION E-MAIL AND SUBJECT HERE $recipient = 'cmboling@windsorexteriors.com'; $subject = 'New Message from Winsor Exteriors'; // END CUSTOMIZATION HERE $postArray = array_keys($_POST); $countHolder = count($postArray); $countCompare = $countHolder - 3; $i = 0; $completeMessage; foreach($postArray as $Arr) { if($i <= $countCompare) { $completeMessage .= $postArray[$i]. " = " .$_POST[$postArray[$i]]. " \n"; $i++; } } mail($recipient, $subject, $completeMessage); $msg = "success"; unset($_SESSION['security_code']); } else { // fail message, change between quotations if you want $msg = "All fields must be filled out properly, please try again"; } } #DOWN TO THIS QUESTION MARK ?>
|
|
|
|
||||||||||
|