You need to attached this code that works perfectly.
PHP Code:
<Php
ini_set('Error_reporting', E_ALL);
ini_set('Display_errors', 1);
if (Mail('Destinataire@domain.tld', 'Subject', 'Message')) echo E-mail sent! ";
else echo 'Failed ...';
?>
For your php.ini file:
PHP Code:
SMTP = smtp.free.fr
smtp_port = 25
sendmail_from = adresse.valide
Regarding your freebox, remember that free blocks port 25 by default and there is a box to uncheck in the interface of your user account. No need to open your port or redirect it to an address of your network, do this instead:
- Go into your main account
- Features the Freebox router
- To enable the routers NAT your Freebox: click here
- Other features: Set
- Uncheck: Blocking outbound SMTP (activate)
Bookmarks