Jump to content

No mail sent


timmah1

Recommended Posts

Can anybody tell me why this isn't sending the email?

function fsendAdminEmail($arrFormInfo,$arrCustDesc){
	$to  = "[email protected]"; 
	//$to  = $gEmails['Info']; 
	$subject = "CCHS More information request";
	$message = "CCHS More information request\r\n";
	$message .= "Email: ".$arrFormInfo['email']."\r\n";
	$message .= "FirstName: ".$arrFormInfo['fname']."\r\n";
	$message .= "LastName: ".$arrFormInfo['lname']."\r\n";
	$message .= "Title: ".$arrFormInfo['title']."\r\n";
	$message .= "PhoneNumber: ".$arrFormInfo['phone']."\r\n";
	$message .= "Address: ".$arrFormInfo['address']."\r\n";
	$message .= "Address2: ".$arrFormInfo['address2']."\r\n";
	$message .= "City: ".$arrFormInfo['city']."\r\n";
	$message .= "State: ".$arrFormInfo['state']."\r\n";
	$message .= "Zip: ".$arrFormInfo['zip']."\r\n";
	$message .= "Country: ".$arrFormInfo['country']."\r\n";
	$message .= "adkey: ".$arrFormInfo['adkey']."\r\n";
	$message .= "adkey_ext: ".$arrFormInfo['adext']."\r\n";
	$message .= "source: ".$arrFormInfo['adsource']."\r\n";

	$message .= "MoreInfoOn: ".$arrCustDesc['programnumber']." -- ".$arrCustDesc['programname']." " .$arrCustDesc['programdesc']."\r\n";
	$message .= "Source Cookie: ".$arrFormInfo['advsource']."\r\n";
 	$message .= "kw: ".$arrFormInfo['advkw']."\r\n";
	$message .= "Request Type: ".$arrCustDesc['requesttypedesc']."\r\n";	

	$headers  = "MIME-Version: 1.0\r\n";		
	$headers .= "Content-type: text/plain; charset=iso-8859-1\r\n";	
	$headers .= "From: ".$arrFormInfo['fname']." ".$arrFormInfo['lname']." <".$arrFormInfo['email'].">\r\n";		

	if(mail($to, $subject, $message, "$headers \r\n From: Test"))
			echo "Message Sent";
	else
  			echo "Message failure";
	}

 

Thanks in advance

Link to comment
https://forums.phpfreaks.com/topic/131883-no-mail-sent/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.