1

I am running a windows server (windows 7) with IIS 7. ESMTP MailEnable is running on port 25. I am also running apache and php on the server. When I use php's mail() it returns false indicating that it can't connect to the outgoing SMTP server (at least I believe that's what it means). I can tell that MailEnable is running because when I run

>telnet localhost 25

the response is

220 WDC1358.home ESMTP MailEnable Service, Version: 5.10-- ready at 06/18/11 20:06:43

I am at a loss for why this is not working with php. Any help would be greatly appreciated.

cstamas
  • 6,707
  • 25
  • 42
Explosion Pills
  • 221
  • 1
  • 2
  • 10
  • Have you checked the PHP error log as well as MailEnable SMTP log (MainEnable Administrator -> Servers -> localhost -> Connectors -> SMTP -> Logs -> Debug)? MailEnable log should tell the possible reason. – LazyOne Jun 18 '11 at 20:55

1 Answers1

1

I think you need to enable Mail Relay for local address.

Allow relay for privileged IP ranges. Allows people with certain IP addresses to send email through the server. If the IP addresses of persons who are able to send email out through the server is known, use this option. DO NOT select this option if the list of IP addresses is unknown, as this may inadvertently allow everyone access. This option is usually required to allow sending through the server from a web server or web page.

MainEnable Administrator -> Servers -> localhost -> Connectors -> SMTP -> Properties -> Relay -> Enable Mail Relay -> Allow relay for privileged IP ranges. Add your IP there (simple "127.0.0.1" should work fine).

LazyOne
  • 3,064
  • 1
  • 18
  • 16