In Codigniter is use this PHP Code to send mail using SMTP
Simple Mail Transfer Protocols :)
$mail = array();
$mail["protocol"] = "smtp";
$mail["smtp_host"] = "ssl://p3plcpnl019.prod.phx3.secureserver.net";
$mail["smtp_port"] = 465;
$mail["smtp_user"] = "Your Email Address";
$mail["smtp_pass"] = "Your Address";
$this->load->library("email", $mail);
$this->email->set_newline("\r\n");
//set email information and content
$this->email->from("support@gerosport.com", "GeroSport");
$this->email->to($to);
$this->email->subject($subject);
$this->email->message($msg);
if($this->email->send())
{
$response = 1;
} else {
$response = 0;
}
Also i get help from :-
http://asif18.com/7/php/send-mails-using-smtp-in-php-by-gmail-server-or-own-domain-server/
No comments:
Post a Comment