RE: Problem in sending email from localhost

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



1)  Which SMTP server are you trying to use?  On your local system? Or
smtp.gmail.com?
2a) If local system, which are are using?  MS' SMTP or 3rd party like hmail?
Are you sure the server is configured properly and that the service is
running?  Run this in command prompt:  

netstat -ano | more

You should see something like this:

Proto  Local Address          Foreign Address        State           PID
 TCP    0.0.0.0:25             0.0.0.0:0              LISTENING       2744

If not, then that's your problem.  You don't have a SMTP server/service
running.  Notice that last number.  If you're running MS' SMTP, in the
taskmanager, it should match up with the process inetinfo.exe.  If you're
using 3rd party, it should match up with their executable.  In the case of
hmail, it should be hmailserver.exe.

2b)  If you're using gmail's, from the same system that your PHP code
resides on, are you able able to connect to the gmail's SMTP using Outlook
Express to check the validity of the account and no misconfigured
firewalls/routers (both hardware and software)?

3)  Run phpinfo();  and check "Loaded Configuration File" to ensure that
it's loading the right php.ini file.  Sometimes you think it loads the right
one but it doesn't.  Don't assume.  Verify.  Then either scroll down or
CTRL+F and look for 'SMTP'.  It should be as you configured it, that is if
it loads the php.ini file from the correct location.

FYI,  I suggest you stay away from non official packaged distributions as
those tend to put things in places you'll least expect.  Getting the
official distribution is strongly advised.  It may take you longer to
understand and get things going.  But in the long run, that knowledge can
further aid you as you can fine tune the configurations to your specific
needs and also helps with the troubleshooting of various errors like the one
you're having now.  Furthermore, should the need arise when you have to
upgrade for any reason, you don't have to rely on non official distribution
as sometimes those won't be updated quickly enough, especially when there's
a security bug fix release.

Regards,
Tommy


-- 
PHP Windows Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[Index of Archives]     [PHP Home]     [PHP Users]     [PHP Database Programming]     [PHP Install]     [Kernel Newbies]     [Yosemite Forum]     [PHP Books]

  Powered by Linux