General Email Inquiries:

trim($_POST['emailName']), "emailAddress" => trim($_POST['emailAddress']), "emailSubject" => trim($_POST['emailSubject']), "emailComments" => trim($_POST['emailComments']), "sendCopy" => trim($_POST['sendCopy'])); // build array of survey information if (trim($_POST['industryBreed']) == "(please specify breed)") { $industryBreed = ""; } else { $industryBreed = trim($_POST['industryBreed']); } if (trim($_POST['industryOther']) == "(please specify role)") { $industryOther = ""; } else { $industryOther = trim($_POST['industryOther']); } if (trim($_POST['discipline']) == "(please specify)") { $discipline = ""; } else { $discipline = trim($_POST['discipline']); } if ($_POST['industry'] != "") { while (list($key, $val) = each($_POST['industry'])) { $industry .= "$val, "; } $industry = ltrim(rtrim($industry, ", "), "Array"); } $surveyInfo = array("Gender" => trim($_POST['gender']), "Age" => trim($_POST['age']), "City" => trim($_POST['city']), "Province" => trim($_POST['province']), "Country" => trim($_POST['country']), "Income" => trim($_POST['income']), "Horsemanship" => trim($_POST['horsemanship']), "Industry" => $industry, "IndustryBreed" => $industryBreed, "IndustryOther" => $industryOther, "Discipline" => $discipline, "Timeframe" => trim($_POST['timeframe']), "Comments" => trim($_POST['comments'])); if (!(empty($_POST['emailName']) || empty($_POST['emailAddress']) || empty($_POST['emailSubject']) || empty($_POST['emailComments']))) { // submission can be sent // send email to Cuatro L call_user_func('sendEmail', $emailInfo, $surveyInfo); // send email to user if ($emailInfo['sendCopy']) { call_user_func('sendCopy', $emailInfo, $surveyInfo); } } else { // form is incomplete $msgToUser = "Please complete all fields."; call_user_func('displayForm', $emailInfo, $surveyInfo, $msgToUser); } } else { // first time here $surveyInfo = array("IndustryBreed" => "(please specify breed)", "IndustryOther" => "(please specify role)", "Discipline" => "(please specify)"); call_user_func('displayForm', $emailInfo, $surveyInfo, $msgToUser); } ?>

BACK TO CONTACTS

 
 

We have moved to a form method of receiving e-mail to cut down on the quantity of spam e-mail we receive. Please use the following form to send us an email. We look forward to receiving your message and we will respond promptly.

Your Name:
Your Email Address:
Email Subject:
Your Message to Us:
  > Send a copy of my message to me.

In order to serve you better, we would like to know more about our potential buyers. We would appreciate your answers to the following questions:

Gender: > Male
> Female
Age: > under 18
> 18 - 25
> 26 - 45
> over 45
City:
Province/State:
Country:
Income Level: > under $30,000
> $30,000 to $50,000
> over $50,000
Horsemanship Level: > Beginner
> Intermediate
> Advanced
Involvement in the
Horse Industry:

(check all that apply)
> Trainer
> Rider
> Breeder:
> Other:    
Discipline:
Time Frame for
Purchase from
Cuatro L:
> in the next 30 days
> in the next 6 months
> in the next year
> no time frame in mind
Other Comments:

$subject
"; // echo "$message

"; mail('info@andalusianbreeder.com', $subject, $message, $header); // info@andalusianbreeder.com call_user_func('emailSent', $emailInfo, $surveyInfo); } // construct and send email to user // 2006-Feb-07 (CE): header and subject hard-coded to prevent email injection attacks function sendCopy ($emailInfo, $surveyInfo) { $header = "From: \"Cuatro L Andalusian Breeding Centre Ltd.\" \nX-Mailer: PHP"; $subject = "Your Copy of Email to Cuatro L Andalusian Breeding Centre Ltd."; $message = "You sent the following message to Cuatro L Andalusian Breeding Centre Ltd:\n\n"; $message .= "Subject: {$emailInfo['emailSubject']}\n\n{$emailInfo['emailComments']}\n\n"; // need to check if any information is in the surveyInfo array and include it in the email. reset($surveyInfo); $isAnswered = false; while (list($key, $val) = each($surveyInfo)) { if (! empty($val)) { $isAnswered = true; $surveyAnswers .= "$key: $val\n"; } } if ($isAnswered) { $message .= "The following survey comments were also included:\n\n"; $message .= $surveyAnswers; } else { $message .= "No survey responses were submitted.\n\n"; } $message = wordwrap(stripslashes($message), 70); //echo "

$subject
"; //echo "$message

"; // email message to user mail($emailInfo['emailAddress'], $subject, $message, $header); // notify user of the action echo "

A copy of your email message was sent to the email address provided.

"; } function emailSent ($emailInfo, $surveyInfo) { ?>

Thank-you for your message. We will contact you as soon as possible.

Here is what you sent:

Your Name:
Your Email Address:
Your Email Subject:
Your Message to Us:
$key: \n"; $surveyAnswers .= "". stripslashes($val) ."\n"; } } if ($isAnswered) { echo "

The following survey answers were submitted:

"; echo "$surveyAnswers
"; } else { echo "

No survey responses were submitted.

"; } } ?>