Hi Matt, I apologise for that - I thought that since the code to add the contact to the mailing list worked on its own then I didn't need to supply it...but here is the code I'm working with in its entirety, with some aspects omitted. --- <?php include_once('ConstantContact.php'); $ConstantContact = new ConstantContact('basic', "API Key", "username", "password"); ?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <title>Page Title</title> </head> <body> <?php $fname = $_POST['FName']; $lname = $_POST['LName']; $address = $_POST['Address']; $towncity = $_POST['TownCity']; $countystate = $_POST['CountyState']; $postcodezip = $_POST['PostCodeZip']; $countryregion = $_POST['CountryRegion']; $telephone = $_POST['Telephone']; $email = $_POST['Email']; $divingqualification = $_POST['DivingQualification']; $liveaboard = isset($_POST['Liveaboard']); $destination = $_POST['Destination']; $airport = $_POST['Airport']; $traveldate = $_POST['DateOfTravel']; $duration = $_POST['Duration']; $party = $_POST['NumberTravelling']; $notes = $_POST['SpecialRequests']; if(isset($_POST['RedSea'])) $redsea = $_POST['RedSea']; else $redsea = ' '; if(isset($_POST['Worldwide'])) $worldwide = $_POST['Worldwide']; else $worldwide = ' '; if(isset($_POST['Nature'])) $nature = $_POST['Nature']; else $nature = ' '; if(isset($_POST['Italy'])) $italy = $_POST['Italy']; else $italy = ' '; if(isset($_POST['Turkey'])) $turkey = $_POST['Turkey']; else $turkey = ' '; if(isset($_POST['Canaries'])) $canaries = $_POST['Canaries']; else $canaries = ' '; $checkbox = isset($_POST['JoinNewsletter']); $nosend = "<h2>Your Enquiry was not sent.</h2> \n"; if (eregi('http:', $notes)) { die ("Do NOT try that!!"); } $email=strtolower($email); if(!$email == "" && (!strstr($email,"@") || !strstr($email,"."))) { echo $nosend; echo "<h2>Please return to the previous window and make sure to enter a valid E-Mail address.</h2>\n \n"; die; } if(empty($fname) || empty($lname) || empty($email)) { echo $nosend; echo "<h2>Please return to the previous window and make sure that you have entered your name and e-mail address.</h2>\n \n"; die; } $attn = "Website Booking Enquiry"; $subject = $attn; $notes = stripcslashes($notes); $message = "Booking Enquiry\n \n Name: $fname $lname\n \n Address: $address\n \n Town or City: $towncity\n \n County or State: $countystate\n \n Post/Zip Code: $postcodezip\n \n Country or Region: $countryregion\n \n Telephone: $telephone\n \n Email: $email\n \n Diving Qualification: $divingqualification\n \n Liveaboard Preferred: $liveaboard\n \n Destination: $destination\n \n Airport Preference: $airport\n \n Date of Travel: $traveldate\n \n Duration: $duration\n \n Number Travelling: $party\n \n Special Requests: $notes\n \n Areas of Interest:\n $redsea; $worldwide; $nature; $italy; $turkey; $canaries";$from = "From: $email\r\n"; if($checkbox=="NO") mail("email@address.com", $subject, $message, $from); else { $search = $ConstantContact->searchContactsByEmail($email); $result = $ConstantContact->getContactDetails($search[0]); if($email == $result->emailAddress) { echo "Already on the list"; mail("email@address.com", $subject, $message, $from); } else { $lists = $ConstantContact->getLists(); $contactObj = new Contact(); $contactObj->lists = array($lists['lists'][0]->id); $contactObj->emailAddress = $email; $contactObj->firstName = $fname; $contactObj->lastName = $lname; // Create the contact $Contact = $ConstantContact->addContact($contactObj); echo "<h2><p align='center'>Thank you for joining our mailing list!</p></h2>"; mail("email@address.com", $subject, $message, $from); } } ?> <br /><br /> <p align="center"><strong>Thank you for your enquiry!</strong></p> <p align="center"><strong>The form has been submitted and is being processed by Company Name.</strong></p> <p align="center"><strong>You will be contacted by Company Name A.S.A.P.</strong></p> <br /> <br /> </body> </html> --- That's the code without the stylesheet applied. Regarding the SMTP issue...when you say 'Mail Server' are you referring to the the one the e-mail address is registered with (i.e. the hosting service we use, rather than the program we use to view our e-mails? ) I don't have direct access to our server information as all of this is handled by our offsite technical support company. Could you let me know what I should instruct them to look for so this issue can be resolved? Many Thanks and Kind Regards.
... View more