mail function from and reply to address problem

From: Date: Thu, 12 Jul 2007 23:33:02 +0000
Subject: mail function from and reply to address problem
Groups: php.general 
Request: Send a blank email to php-general+get-258732@lists.php.net to get a copy of this message
I am currently running PHP 5.1.4 Fedora Core 5 i'm trying to exectute the following test script. <?php
$to      = 'my.email@address.com';
$subject = 'the subject'; $message = 'body'; $headers = 'From: webmaster@domain.com' . "\r\n" . 'Reply-To: webmaster@domain.com' . "\r\n" . 'X-Mailer: PHP/' . phpversion(); mail($to, $subject, $message, $headers); ?> i have about 10 or so different virtual hosts running on this machine, and if i use any of them for the from & reply-to addresses, it works fine, or even if i use domains I don't control like aol.com or example.com those work too, but one particular new virtual host doesn't work, it re-writes the from address to the default virtual host address. which is strange because that isn't in the php.ini anywhere, but it could just be taking the hostname. anyone have any ideas? thanks in advance. Tanner

« previous php.general (#258732) next »