Hi All.
I search also for a solution to use SMTP server and I'm surprise when you said that
Code: Select all
ini_set("SMTP","mail.yarncourtesans.com");
ini_set("smtp_port","25");
work for you, because when I edit my php.ini file, there is this mention :
Code: Select all
[mail function]
; For Win32 only.
SMTP = smtp.xxx.xx
smtp_port = 25
As you can read, this value are only for windows and in the PHP documentation, there is the same warning :
http://fr3.php.net/manual/fr/ref.mail.php#ini.smtp
So, I'm just surprised that nobody has mentioned that.
Edit :
Finaly, I find a simple way to use an SMTP server.
Instead of sendmail, I use ssmtp on my system (Gentoo linux).
ftp://ftp.debian.org/debian/pool/main/s/ssmtp/
You have only to specify your smtp server in the config file and all services will use it (including apache/php).
OK, you must be root on your host ... but it work
