Re: Sending mail on OS X

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



I'm pretty sure you want \r\n instead of \n\r, though as you only have
one header and nothing after it, it doesn't matter maybe...

You may also need to LOGIN to your SMTP server, from your PHP server,
before you try to send mail through it.

Some servers allow only specific IP (other servers in the LAN) *OR*
logged in users from the outside world, so maybe that will get you
through.

Or maybe not, depending on the SMTP server settings.

Only the server of the SMTP box can really tell you what will or won't
work.

On Fri, June 8, 2007 11:04 pm, Christian Cantrell wrote:
> Hi, all.  I'm sure this question has been asked, but I was not able to
> effectively search the forum archives, so I'm having to ask it again.
>
> I'm trying to use the mail function to send email on OS X, but the
> email
> gets rejected by the mail server I'm sending to.  I get messages in
> mail.loglike this:
>
> "The IP you're using to send email is not authorized to send email
> directly
> to our servers."
>
> I tried sending mail through another server using the SMTP and
> smtp_port
> settings in my php.ini files, but the settings seem to be ignored
> (perhaps
> they are Windows only?).  Can anyone tell me how I can successfully
> send
> test emails on OS X?
>
> Also, the From header does seem to be getting successfully set.  Is
> there
> anything wrong with this code?
>
> mail('foo@xxxxxxx', 'php test', 'this is the message.\nthis is another
> line.', 'From: qantrell@xxxxxxxxx'."\n\r");
>
> Thanks,
> Christian
>


-- 
Some people have a "gift" link here.
Know what I want?
I want you to buy a CD from some indie artist.
http://cdbaby.com/browse/from/lynch
Yeah, I get a buck. So?

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux