Failed to connect to the mail server on the localhost port 25

I have a little problem.

When I click the submit button in my contact form, I get the following warning:

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

I am using 64-bit Win7, but I have no idea what I need to configure to make this work.

+3
source share
1 answer

In your php.ini file, you can configure which mail server to use:

[mail function]
SMTP = mymailserver.example.com

Alternatively, you can install a local mail server as described here: http://www.php.net/manual/en/ref.mail.php#77499

+2
source

Source: https://habr.com/ru/post/1750813/


All Articles