Use PHP mail() Function with Exim4

Edit the file

/etc/php5/apache2/php.ini
or
/etc/php/7.0/apache2/php.ini

and add the line

sendmail_path = "/my_custom_path/exim -t"

without the option -i which will cause problems.

Usually, “/my_custom_path/” = “/usr/sbin/”. Use “whereis” to know where exim is intalled.

Leave a Reply