macole111 Posted October 24, 2011 Share Posted October 24, 2011 Hi, I have php installed on IIS 7.5 fine, moving from another (slower) 7.5 server. On that server I used fake sendmail (http://glob.com.au/sendmail/) fine and all worked. Now moving onto the new server I have had no problems with PHP except it won't send emails! Fake sendmail is working fine as the following batch file sends an email fine: @ECHO OFF REM send email from command line via SMTP with sendmail ECHO From: someone@example.com > %TEMP%\temp.mail ECHO To: anemail@example.com. >> %TEMP%\temp.mail ECHO Subject: this is a test >> %TEMP%\temp.mail ECHO.>> %TEMP%\temp.mail ECHO testing. >> %TEMP%\temp.mail ECHO blah blah.. >> %TEMP%\temp.mail ECHO. >> %TEMP%\temp.mail ECHO blah. >> %TEMP%\temp.mail C:\usr\bin\sendmail -t < %TEMP%\temp.mail DEL %TEMP%\temp.mail My php.ini mail section looks like this: [mail function] ; For Win32 only. ; http://php.net/smtp ;SMTP = localhost ; http://php.net/smtp-port ;smtp_port = 25 ; For Win32 only. ; http://php.net/sendmail-from ;sendmail_from = me@example.com ; For Unix only. You may supply arguments as well (default: "sendmail -t -i"). ; http://php.net/sendmail-path sendmail_path = C:\usr\bin\sendmail.exe -t -i ; Force the addition of the specified parameters to be passed as extra parameters ; to the sendmail binary. These parameters will always replace the value of ; the 5th parameter to mail(), even in safe mode. ;mail.force_extra_parameters = ; Add X-PHP-Originating-Script: that will include uid of the script followed by the filename mail.add_x_header = On ; The path to a log file that will log all mail() calls. Log entries include ; the full path of the script, line number, To address and headers. mail.log = C:\usr\bin\phpemail.log The mail log shows all the emails that should have been sent with PHP fine. Any ideas? Thanks, macole111 Quote Link to comment https://forums.phpfreaks.com/topic/249708-fake-sendmail-not-working/ Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.