djanim8 Posted August 12, 2007 Share Posted August 12, 2007 I get this any time I try to send an email to someone that IS NOT in the domain of the company: Warning: mail() [function.mail]: SMTP server response: 503 This mail server requires authentication when attempting to send to a non-local e-mail address. Please check your mail client settings or contact your administrator to verify that the domain or address is defined for this server. in corpevent.php on line 21 I have it setup like this (I removed the email address domain...but its correct in the code): // INI Settings // ini_set(sendmail_from,"info@domain.com"); ini_set(SMTP,"mail.domain.com"); ini_set(smtp_port,"25"); $headers = "MIME-Version: 1.0\r\n"; $headers .= "Content-type: text/html; charset=iso-8859-1\r\n"; $headers .= "From: info@domain.com"; $to = $_POST['txtEmail']; mail($to,"Your Email",$theEmail,$headers); Why am I not allowed to send an email to anyone that doesn't have a "domain.com" at the end of the email? Quote Link to comment https://forums.phpfreaks.com/topic/64543-problems-with-mail/ Share on other sites More sharing options...
djanim8 Posted August 12, 2007 Author Share Posted August 12, 2007 btw.. (and this is odd)... I have another page that is in the root of the domain (http://www.domain.com/) and it DOES send an email to the person thats NOT on the domain... this code is in a folder called corpevent (http://www.domain.com/corpevent/) and doesn't work.... Quote Link to comment https://forums.phpfreaks.com/topic/64543-problems-with-mail/#findComment-321730 Share on other sites More sharing options...
djanim8 Posted August 13, 2007 Author Share Posted August 13, 2007 ok I downloaded and used the PHP Mailer (http://phpmailer.sourceforge.net/) but I get this error when I try to send an email: SMTP Error: The following recipients failed: On their FAQ page (http://phpmailer.sourceforge.net/faq.html#faq1), it says this: I am getting a "SMTP Error: The following recipients failed [myemail@mydomain]" This error usually occurs because relaying is not allowed on the SMTP server from the IP address of the web server. Go to the configuration of your SMTP server and turn relaying on for your IP address and try again. I don't know how to fix that.. how would I go about fixing that? Quote Link to comment https://forums.phpfreaks.com/topic/64543-problems-with-mail/#findComment-322015 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.