Jump to content

[SOLVED] mail function doesn't do From correctly


mapleleaf

Recommended Posts

This is an extract from the PHP manual on mail():

<?php
$to      = '[email protected]';
$subject = 'the subject';
$message = 'hello';
$headers = 'From: [email protected]' . "\r\n" .
    'Reply-To: [email protected]' . "\r\n" .
    'X-Mailer: PHP/' . phpversion();

mail($to, $subject, $message, $headers);
?>

 

Full page: http://uk3.php.net/manual/en/function.mail.php

 

That line of code you posted - is that the exact line you're using in your script?

 

btw, notice the example I first changed I swapped your single quotes for double.

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.