Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to configure php.ini file for mail() in MAC OS?

Tags:

php

sendmail

I'm using MAC OS and using mail() to send the student details to my mail.

It does not shows any errors, but the details are not sent to mail.

Is there any setup in php.ini for SMTP settings?

like image 818
M S Reddy Avatar asked Nov 17 '11 05:11

M S Reddy


2 Answers

For OSX Yosemite, this fixed me right up:

; For Unix only.  You may supply arguments as well (default: "sendmail -t -i").
; http://php.net/sendmail-path
SMTP=localhost
smtp_port=25
sendmail_path = "env -i /usr/sbin/sendmail -t -i"

Ensure that you have your postfix configured - check out this link to learn more: http://benjaminrojas.net/configuring-postfix-to-send-mail-from-mac-os-x-mountain-lion/

like image 187
Moe Avatar answered Sep 22 '22 10:09

Moe


Mac and php's mail - it's simple.
Check this beautiful article:
http://theandystratton.com/2009/fix-phps-mail-function-after-latest-os-x-leopard-update

like image 3
cetver Avatar answered Sep 23 '22 10:09

cetver