Re: php mail() not sending to mail Clients (ie, Outlook, Apple Mail, thunderbird, etc..)



shybe wrote:
I have a send mail script on my site that.

The emails are recieved by gmail, and yahoo, but not to mail clients
like Outlook, Mail, etc...)

Is this a problem with the script, or is it something I must change in
php ini file?

Thanks in advance for any help.

here is the code. (im using it in conjunction with javascript for some
AJAX stuff)

if(!isset($_GET['action']))
{
die("You must not access this page directly!"); //Just to stop people
from visiting contact.php normally
}

/* Now lets trim up the input before sending it */

$name = trim($_GET['name']); //The senders name
$to = trim($_GET['maily']); //The senders email address
$place = trim($_GET['place']); //The senders email address
$subject = "you have recieved mail";
$headers = "From:$name";
$message = "{$name} deemed you worthy of receiving the following
information/exchange from Trumpet.\n\n Follow This Link {$place}";
mail($to, $subject, $message,$headers); //a very simple send

echo 'contactarea|<p class="sent">Article Sent!</p>'; //now lets
update the "contactarea" div on the contact.html page. The
contactarea| tell's the javascript which div to update.

?>


It's not a problem with the mail() function if some e-mail clients are
getting it. Maybe something to do with your e-mail formatting:

$headers = "From: $name"; should probably be
$headers = "From: \"$name\" <$email>";

Also the code snippet as you posted would be very vulnerable to script
attacks, I suggest more secure code.
.



Relevant Pages

  • "Find Album Info" declares a script error at metaservices.windowsmedia.com!
    ... The script debugger says this error is a Microsoft ... This div is styled with display: ... So apparently .reload isn't supported on ...
    (microsoft.public.windowsmedia.player)
  • apache SSI and failing CSS
    ... The CGI script is doing what I asked it to do but ... standard complement of DOCTYPE, html, head and body tags. ... ..includes-homepage DIV { ... The H1 and P classes seem to work but the DIV class seems to be ...
    (comp.infosystems.www.servers.unix)
  • Re: Script in AJAX-loaded page inside parent page not firing
    ... there is a button that fires an XMLHTTP event: ... The result is that SrchFrm.aspx is loaded in a DIV on Page.aspx. ... If I test this script in SrchFrm.aspx (without ... When Ajaxxing it would be better that the "donwloaded" files have no HEAD nor body or html tags ... ...
    (comp.lang.javascript)
  • Re: Sending many files attachment with mailx
    ... mail clients but not Lotus Notes. ... Here's the script: ... On Lotus Notes: just the first file is attached, ... My recommendation for composing or de-composing MIME conforming emails ...
    (comp.unix.solaris)
  • Re: php mail() not sending to mail Clients (ie, Outlook, Apple Mail, thunderbird, etc..)
    ... The emails are recieved by gmail, and yahoo, but not to mail clients ... contactarea| tell's the javascript which div to update. ... Also the code snippet as you posted would be very vulnerable to script ...
    (comp.lang.php)