|
|
Contact Us
Name";
}
if ($_POST['email']=="")
{
$missing=$missing."E-mail";
}
// Added by Adam 28/06/2004
if ($_POST['heard']=="")
{
$missing=$missing."Where did you hear about the Namaste website";
}
if ($missing!="")
{
?>
Sorry, it looks like you have missed out some required fields.
Please
Click Here to go back
Back to Top
}
else
{
// processmail.php Lane Global Resourcing Ltd Build - Web On High - 20/05/2002
include "mime_mail.inc";
// Check for attachment and if there is one do the following
$attach = $_FILES['attach']['tmp_name'];
$attach_type = $_FILES['attach']['type'];
$attach_name = $_FILES['attach']['name'];
If ($attach!="") {
// Upload the file to the server
If (copy($attach, "temp.txt")) {
$attachment = True;
} else {
$attachment = False;
}
unlink($attach);
}
// create object instance
$mail = new mime_mail;
// set all data slots
$mail->from = $_POST['email'];
$mail->to = $_POST['to'];
$mail->subject = "Contact from Namaste web site";
$mail->body .= "The following contact request has been received:\n\n";
$mail->body .= "Company Details\n\n";
$mail->body .= "Company Name: ".$_POST['company_name']."\n";
$mail->body .= "Contactee Position : ".$_POST['company_position']."\n";
$mail->body .= "Address: ".$_POST['company_address']."\n";
$mail->body .= "Town/City: ".$_POST['company_town_city']."\n";
$mail->body .= "County/State: ".$_POST['company_state_county']."\n";
$mail->body .= "Postcode: ".$_POST['company_postcode']."\n";
$mail->body .= "Country: ".$_POST['company_country']."\n";
$mail->body .= "Telephone: ".$_POST['company_telephone']."\n";
$mail->body .= "Fax: ".$_POST['company_fax']."\n";
$mail->body .= "Email: ".$_POST['company_email']."\n";
$mail->body .= "\n";
$mail->body .= "Personal Details\n\n";
$mail->body .= "Name: ".$_POST['name']."\n";
$mail->body .= "Address: ".$_POST['address']."\n";
$mail->body .= "Town/City: ".$_POST['town_city']."\n";
$mail->body .= "County/State: ".$_POST['state_county']."\n";
$mail->body .= "Postcode: ".$_POST['postcode']."\n";
$mail->body .= "Country: ".$_POST['country']."\n";
$mail->body .= "Telephone: ".$_POST['telephone']."\n";
$mail->body .= "Fax: ".$_POST['fax']."\n";
$mail->body .= "Email: ".$_POST['email']."\n";
$mail->body .= "\n";
$mail->body .= "Services Of Interest \n\n";
$mail->body .= "Projects: ".$_POST['projects']." \n";
$mail->body .= "Training: ".$_POST['training']." \n";
$mail->body .= "Consultancy: ".$_POST['consultancy']." \n";
$mail->body .= "Management Guides: ".$_POST['management_guides']." \n";
$mail->body .= "Outline Of Requirements: ".$_POST['requirement']." \n";
$mail->body .= "\n";
$mail->body .= "Nameste Fun\n\n";
$mail->body .= "Create A Tailor Made Adventure: ".$_POST['create']." \n";
$mail->body .= "Join The Global expedition: ".$_POST['join']." \n";
$mail->body .= "Outline Of Requirements: ".$_POST['requirement-fun']." \n";
$mail->body .= "Management Guides: ".$_POST['management_guides']." \n";
$mail->body .= "Tell Nameste About You: ".$_POST['about_you']." \n";
$mail->body .= "\n";
$mail->body .= "Nameste News\n\n";
$mail->body .= "Join Newsletter: ".$_POST['news']."\n";
$mail->body .= "\n";
$mail->body .= "Website Feedback\n\n";
// Added by Adam 28/06/2004
$mail->body .= "Where Did You Hear About Namaste Website: ".$_POST['heard']." \n";
$mail->body .= "What Think Of Web Site: ".$_POST['what_you_think']." \n";
$mail->body .= "Anything Else: ".$_POST['anything_else']." \n";
// If there was actually an attachment append it as an attachement
If ($attachment == True) {
// retain the name of the file including the extension
$output = ("$attach_name");
// build the file as an attachment
$filename = "temp.txt";
$fd = fopen($filename, "r");
$data = fread($fd, filesize($filename));
fclose($fd);
// append the attachement
$mail->add_attachement($data, $output);
}
// send email
$mail->send();
//echo("email sent successfully");
?>
Thank You. We will respond to your enquiry as soon as possible. Namaste
Click
Here to continue browsing.
Back to Top
}
?>
|