Here is the php snippet that I used to send email.
Code: Select all
<?php
if (mail('valid address over here', 'Subject', 'Your message here.')) {
echo('<p>Mail sent successfully.</p>');
} else {
echo('<p>Mail could not be sent.</p>');
}
?>Here are my system configurationPHP Warning: mail() [<a href='function.mail'>function.mail</a>]: SMTP server response: 550 5.7.1 Relaying not allowed: <valid email address over here> in C:\\Program Files\\Apache Software Foundation\\Apache2.2\\htdocs\\email.php on line 2
Apache - PHP setup is working fine.Windows XP Pro
Apache 2.2.4
PHP 5.2.3
I'm using a Broandband account and using a SMTP server of the same
I have configured the php.ini for the SMTP setup
Please suggest a solution to fix the error that I receive.[mail function]
; For Win32 only.
SMTP = <broadband smtp server over here>
smtp_port = 25
; For Win32 only.
sendmail_from = <valid email address over here>
Thanks
Prakash A