Wednesday, May 14, 2014

PHP Mavericks, XAMPP and Sendmail Oh My!

First back up the file we’ll edit -
cp /etc/postfix/main.cf  /etc/postfix/main_orig.cf
then edit it -
sudo vi /etc/postfix/main.cf
and set
relayhost = [smtp.theserver.edu]
you may be tempted to edit myhostname, or mydomain but just leave them commented out.
save the file
Back up your php.ini file -
cp /Applications/XAMPP/etc/php.ini  /Applications/XAMPP/etc/php_orig.ini
then edit it -
sudo vi /Applications/XAMPP/etc/php.ini
search for SMTP, it may be commented out, but change it to this -
SMTP=localhost
uncomment
smtp_port=25
then change
sendmail_path = /usr/sbin/sendmail -t -i
save the file