NYCPHP Meetup

NYPHP.org

[nycphp-talk] using PHP mail function on Windows server?

Tim Gales tgales at tgaconnect.com
Thu Apr 24 13:51:34 EDT 2008


Kristina Anderson wrote:
> Hi everyone --
>
> My current client's app is a PHP 4 site running on a Windows box (don't 
> ask...I have no idea why).  I'm trying to use the mail() function and 
> the mail isn't cooperating.  
> [...]
> Thanks for any help...
>   
I got this to work once using IIS6 on WindowsXP Prof. which is a lot 
like Windows
Server 2003 (you didn't mention which version Windows you were trying 
this with)

I had the IIS server turned off and used the IIS Manager plugin to point 
the windows
mail server to a Linux mail server relay style. The Linux machine was on 
a private
network but with another public facing interface.

To test it you can
Open a window cmd box and start telnet (set localecho)
and 'open localhost 25'.

You enter 'helo' and get something like '250 10.10.x.x Hello [127.0.0.1]'
mail from:email at any.com   .                '250 2.1.0 
email at any.com....Sender OK'
rcpt to:valid at domain.com                   '250 2.1.5 valid at domain.com
DATA                                                '354 Start mail 
input; end with <CRLF>.<CRLF>'
test test test

.
250 2.6.0 <DESKqjTfLiCiW8St44v00000003 at 10.10.x.x> Queued mail for Delivery

I can mail you the settings for the properties (in the IIS Manager) if 
you want.

-- 

T. Gales & Associates
'Helping People Connect with Technology'

http://www.tgaconnect.com




More information about the talk mailing list