Page 1 of 1

Help with php mail() function, XAMPP package

Posted: Thu Jul 26, 2007 1:24 pm
by mscardenas
Hi all,

I've just installed the latest of the XAMPP package (php5.2.1, mysql5.0.37, apache2, etc). Now I created a form which uses php's mail() function to mail me the form a user has filled up.
I have set the php.ini file in the apache/bin directory to SMTP: http://www.ISPadd.com (my ISP's address), smtp_port = 25, and sendmail_from = mscardenas@yahoo.com (my email address). But I always get this error:

Warning: mail() [function.mail]: Failed to connect to mailserver at "www.ISPadd.com" port 25, verify your "SMTP" and "smtp_port" setting in php.ini or use ini_set()

I tried sending mail using Mercury mail (bundled with XAMPP), and it has successfully send mail. The problem is I don't know how to access Mercury mail through my php form, and I like php's mail() function to handle it. Anyone have an idea what's the error, o how to fix it? Thanks.:)

Posted: Thu Jul 26, 2007 3:47 pm
by miro_igov
I believe this is because http://www.ISPadd.com does not exists or it's port 25 does not accept incoming connections, just did telnet and it failed.