mail() takes a long time to process

From: Date: Sun, 27 Feb 2005 00:25:03 +0000
Subject: mail() takes a long time to process
Groups: php.general 
Request: Send a blank email to php-general+get-209522@lists.php.net to get a copy of this message
Hi there, I have a script that uses the mail() function, but for some reason the script takes a really long time to finish processing (like 5 minutes). there are some other functions performed (like sql insert, etc) that happen immediately as they should. But the mail takes some time to finish processing. If I remove the mail function, the script finishes immediately. Any ideas? I have included my code below (used for the mail). ideas? $ToMail = $_POST['ccEmail']; $FromMail = "some@one.com"; $FromName = "The Name"; $Subject = "Your membership"; $xmailer = "PHP mailer"; $headers = "From: ".$FromName."<".$FromMail.">\r\n"; $headers .= "Reply-To: ".$FromName."<".$FromMail.">\r\n"; $headers .= "X-Mailer: ".$xmailer."\r\n"; $headers .= "Origin: ".$_SERVER['REMOTE_ADDR']."\r\n"; $Message = "Dear ".$_POST['ccfName']."\n,"; $Message .= "Thanks for joining the Coastal Crew!\n"; $Message .= "Below you will find the information required to verfiy your email address.\n"; $Message .= "Upon verification, an e-coupon will be presented to you in which you can print"; $Message .= " off for 20% off of your next purchase.\n\nBy clicking on this hyperlink:\n"; $Message .= $verify_url."\nand follow the directions in your web browser.\n\n"; $Message .= "Thank you,\nThe Coastal Crew.\n".$_SERVER['SERVER_NAME']; $mailer = mail($ToMail, $Subject, $Message, $headers);

« previous php.general (#209522) next »