0

Here's what's in my php.ini file:

[mail function]
; For Win32 only.
; http://php.net/smtp
SMTP = localhost
; http://php.net/smtp-port
smtp_port = 25

Is it possible to simply change localhost to smtp.live.com and change the port (smtp_port) to point to a different port (specifically, 567, as required by Microsoft) in order to send email to a Microsoft Live email address via PHP? I tried the normal mail() route, but I never received the email from the script, and can only assume it has to do with SMTP authentication. I don't have very much experience with PHP.

pnuts
  • 58,317
  • 11
  • 87
  • 139
Mike Marks
  • 10,017
  • 17
  • 69
  • 128

3 Answers3

0

Have a look at PHPMailer : https://github.com/PHPMailer/PHPMailer

I'm using it to send emails through a GMail account, settings are pretty easy!

This way you won't have to update your php.ini

Pascamel
  • 953
  • 6
  • 18
  • 28
0

No, that won't work. smtp.live.com requires authentication, and the PHP mail() command does not support authentication. As Pascamel suggested, you should use a library that supports sending mail through a remote SMTP server using authentication. phpmailer is very good.

mti2935
  • 11,465
  • 3
  • 29
  • 33
0

in php.ini you can change smtp server to different server ONLY for WINDOWS machines. You can't do it for unix machines. it just ignores even if you set smtp = yourserver.

Chakri
  • 549
  • 3
  • 5