[Wolves] Sent from

Re-LoaD reload at brum2600.net
Mon Feb 11 09:01:31 GMT 2008


Wayne wrote:
> Hi,
> 
> When you use php/html/mysql to generate email, where is the email from 
> address generated?
> It seems to be picking up my name from the httpd being set to run under 
> my name, but the domain name does not seem
> to be from 'hostname' or the one set in httpd.conf
> 
> Any ideas?
> 
> ta
> 
> wayne
> 
Always best to RTFM but you are welcome to pull this apart (Bad Code Bad 
Code.... ):-
$myproggy = "DEMO Mailer";
$mailto = $_POST['SendTo'];
$presubject = $_POST['Subject'];
$comments = $_POST['Comment'];
$emailaddy = $_POST['EmailAD'];
$fromname = $_POST['SentFrom'];

$headers = "From:  $fromname <$emailaddy>\r\nX-Mailer: $myproggy";

$subject = "DemoMailFeed: $presubject";

mail("$mailto", "$subject", "$comments", "$headers");


--
Re-LoaD



More information about the Wolves mailing list