php - Codeigniter Email Sending Issue -
this link: http://theartvalley.com/clients/theartvalley.com/
i using in email send code:
<?php include_once (dirname(__file__) . "/load_pages.php"); class generalfunctions extends load_pages { function __construct() { parent::__construct(); } function send_mail(){ $smtp_host = "uscentral48.myserverhosts.com"; $smtp_port = 465; $smtp_user = "admin@theartvalley.com"; $smtp_pass = "sender33"; $send_email = "gnkafridi@gmail.com"; $config = array( "protocol" => "smtp", "smtp_host" => $smtp_host, "smtp_port" => $smtp_port, "smtp_user" => $smtp_user, "smtp_pass" => $smtp_pass, "smtp_crypto" => "ssl", "mailtype" => "html", "charset" => "iso-8859-1", "wordwrap" => true, "wordwrap" => "\r\n" //use double quotes comply rfc 822 ); $name = $this->input->post("name"); $email = $this->input->post("email"); $subj = $this->input->post("subj"); $msg = $this->input->post("msg"); $this->load->library("email", $config); $this->email->from($email, $name); $this->email->to($send_email); $this->email->subject($subj); $this->email->message($msg); if($this->email->send()){ echo "your message has send appropriate email ($send_email)"; } else{ echo "server has busy, please send email manually $send_email"; } } }
and show me error:
a php error encountered severity: warning message: fgets() [function.fgets]: ssl: connection reset peer filename: libraries/email.php line number: 1870 php error encountered severity: warning message: fwrite() [function.fwrite]: ssl: broken pipe filename: libraries/email.php line number: 1847 php error encountered severity: warning message: fwrite() [function.fwrite]: ssl operation failed code 1. openssl error messages: error:1409f07f:ssl routines:ssl3_write_pending:bad write retry filename: libraries/email.php line number: 1847
i don´t understand why require other library , extend it.
$config = array( "protocol" => "smtp", "smtp_host" => $smtp_host, "smtp_port" => $smtp_port, "smtp_user" => $smtp_user, "smtp_pass" => $smtp_pass, "smtp_crypto" => "ssl", "mailtype" => "html", "charset" => "iso-8859-1", "wordwrap" => true, "wordwrap" => "\r\n" //use double quotes comply rfc 822 );
and need change to
$config = array( "protocol" => "smtp", "smtp_host" => $smtp_host, "smtp_port" => $smtp_port, "smtp_user" => $smtp_user, "smtp_pass" => $smtp_pass, "smtp_crypto" => "ssl", "mailtype" => "html", "charset" => "iso-8859-1", "wordwrap" => true, "crlf" => "\r\n" //use double quotes comply rfc 822 );
is thing can see
Comments
Post a Comment