I have been trying to send mail using wamp server in my laptop. The SMTP server is presented in online. Here is my php code to send mail:
<?php
ini_set( 'SMTP', "mail.vickey1192.co.in" );
ini_set( 'smtp_port', 26 );
ini_set( 'sendmail_from', "admin@vickey1192.co.in" );
$to = "balavickey1192@gmail.com";
$subject = "Acknowledgement";
$message = "Thank you for registering with us<br>";
$from = "no-reply@vickey1192.co.in";
$headers = "From:" . $from;
mail($to,$subject,$message,$headers);
echo "Mail Sent.";
?>
I also set my php.ini file like this:
[mail function]
; For Win32 only.
; http://php.net/smtp
SMTP = mail.vickey1192.co.in
; http://php.net/smtp-port
smtp_port = 26
; For Win32 only.
; http://php.net/sendmail-from
sendmail_from = admin@vickey1192.co.in
This is the error I am getting:
Warning: mail() [function.mail]: SMTP server response: 550-Please turn on SMTP Authentication in your mail client, or login to the 550-IMAP/POP3 server before sending your message. (vignesh-PC) 550-[115.118.170.201]:23328 is not permitted to relay through this server 550 without authentication. in C:\wamp\www\mailtofunc.php on line 12
What do I do now? Please help me guys...