The mail() function in php works strange these days.
<?php mail("email@example.com", "Subject", "Content"); ?>
The above script works if I use "php script.php" in command line. However, if I link to the page(http://domain.com/script.php) by browser, the mail will not be sent even if the mail function returns true.
I googled about it and find a solution. It says "modify the php.ini file as following".
sendmail_path = "/usr/sbin/sendmail -t -i"
sendmail_path = "/usr/sbin/sendmail -t"
And it works for me right now. Does anyone know why removing parameter -i can solve the problem? it goes well with -i in the past few months!!