Re: Re: Mail() on OS X [follow up]

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

 



Hello,

On 06/02/2003 12:17 AM, Tony Wu wrote:
ok, i've installed a mail server on my machine (CommuniGate).
But it still doesn't work.
I've specified SMTP server in php.ini.
a frind of mine got it to work with the same configure (CommuniGate) and he said he just put his SMTP in php.ini.
and now we both have tried to get it to work on two local machines with no luck.
what gives?

Forget it, the mail() function never works directly with SMTP servers under Unix like systems like for instance Mac OS X, Linux, etc..


To send messages it uses a mailer program like sendmail. A mailer program is not a SMTP server, although some can act as one, like sendmail, qmail, postfix, etc..

You can however use the class that I mentioned to solve your problem because it can act as a mailer program.



hi all, i am trying to use mail() on Mac OS X 10.2 WITHOUT sendmail.
I have php.ini file in my usr/local/lib directory, with SMTP set to my desire smtp server.
But it just doesn't work.
Does anyone here know how to use mail() on OS X?

No, the mail() function only uses a SMTP server under Unix.


To solve your problem you may want to try this class for composing and sending messages that comes with a subclass for delivering via a SMTP server.

If you do not want to change much your scripts, it comes with a function named smtp_mail() that emulates the mail() function except that it send the messages to SMTP server of your choice:

http://www.phpclasses.org/mimemessage

To send via SMTP you also need this other class:

http://www.phpclasses.org/smtpclass


--

Regards,
Manuel Lemos

Free ready to use OOP components written in PHP
http://www.phpclasses.org/


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


[Index of Archives]     [PHP Home]     [PHP Users]     [Postgresql Discussion]     [Kernel Newbies]     [Postgresql]     [Yosemite News]

  Powered by Linux