Problem sending Mail
| From: | James Duncan | Date: | Sun, 13 Aug 2000 17:15:52 +0000 |
| Subject: | Problem sending Mail | ||
| Groups: | php.windows | ||
| Request: | Send a blank email to php-windows+get-1760@lists.php.net to get a copy of this message | ||
Hi there,
I'm very new to PHP. I've just successfully installed PHP4, Apache and MySQL
on Windows 2000. My first project is a "tell a friend" web page. Obviously
this involves the mail command. I set up the php.ini file to use my ISP's
SMTP server. To keep things very simple I hard coded everything to make sure
the basics worked. My PHP code is:
<?php
mail("jd@jamesduncan.co.uk", "My Subject", "The message");
?>
This worked fine (email correctly sent, etc) when I hooked up my modem
directly to the NT machine running PHP and connected directly to the
Internet. However, my normal set up involves sharing the modem Internet
connection to all my machines via a proxy. I use WinProxy 3
(www.winproxy.com) running on a Win95 machine and all machines are set to
use the proxy, etc. When I run the above PHP script on the NT machine from
behind the proxy PHP reports a timeout error after 30 seconds. The strange
thing is that after the timeout occurs the email is still sent. It seems
that the proxy server isn't cutting the connection with the SMTP server or
something? I have tried altering the PHP.INI file SMTP setting to the IP
address of my proxy server and my ISP's SMTP server IP address but the
problem still occurs.
The code itself is okay so it seems the problem lies with the Proxy server?
Does anyone have any ideas?
Thanks
James