chestnuth Posted March 6, 2008 Share Posted March 6, 2008 i am trying to send an email using PHP, i am using a wamp setup. However i keep gettin errors, any ideas? <?php mail('[email protected]','hello','bodytext'); ?> Warning: mail(): Failed to connect to mailserver at "localhost" port 25, verify your "SMTP" and "smtp_port" setting in php.ini or use ini_set() in Thanks J Link to comment https://forums.phpfreaks.com/topic/94742-emails/ Share on other sites More sharing options...
craygo Posted March 6, 2008 Share Posted March 6, 2008 Pretty much just what it says. You have to go into your php.ini file and setup the smtp. Get setting from ISP and put them into the php.ini file something like this [mail function] ; For Win32 only. SMTP = smarthost.coxmail.com smtp_port = 25 sendmail_from = [email protected] if your smtp server requires authentication you may want to download the phpmailer class. I downloaded it and put it in my includes folder under my php install and that makes it available for every script you write. Ray Link to comment https://forums.phpfreaks.com/topic/94742-emails/#findComment-485086 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.