Re: mail function and headers

From: Date: Wed, 12 Mar 2008 15:11:26 +0000
Subject: Re: mail function and headers
References: 1 2  Groups: php.general 
Request: Send a blank email to php-general+get-271380@lists.php.net to get a copy of this message
2008/3/12, Daniel Brown <parasane@gmail.com>: > You have the From: header parameters reversed. Try this: > > <? > $headers = "From: ".$fromname." <".$email.">\r\n"; > $headers .= "Reply-To: ".$email."\r\n"; > $headers .= "X-Mailer: PHP/".phpversion()."\r\n"; > /* > .... > */ > ?> you can add these headers: $header = "From: $fromname<$email>\n"; $header .= "Reply-To: $email\n"; $header .= "Return-Path: <$email>\n"; $header .= "X-Mailer: PHP/" . phpversion() . "\n"; $header .= "MIME-Version: 1.0\n"; $header .= "Content-type: text/plain; charset=iso-8859-1\n"; $header .= "Content-Transfer-encoding: 7bit\n"; Try it. -- Scripts: http://www.spacemarc.it

« previous php.general (#271380) next »