博客首页|TW首页| 同事录|业界社区
$this->load->library('email');
$from = 'xufeng@techweb.com.cn';//发件人
$to = 'xf1982@gmail.com';//收件人
$subject = 'test send email in codeingiter by smtp';
$body = 'test send email in codeingiter by smtptest send email in codeingiter by smtptest send email in codeingiter by smtptest send email in codeingiter by smtptest send email in codeingiter by smtptest send email in codeingiter by smtptest send email in codeingiter by smtp';
$config['protocol'] = 'smtp';
$config['smtp_host'] = 'ssl://smtp.gmail.com';
$config['smtp_user'] = 'xf1982xf@gmail.com';
$config['smtp_pass'] = '******';
$config['smtp_port'] = '465';
$config['smtp_timeout'] = '5';
$config['newline'] = "\r\n";
$config['crlf'] = "\r\n";
$this->email->initialize($config);
$this->email->set_mailtype('html');
$this->email->from($from, 'title');
$this->email->to($to);
$this->email->subject($subject);
$this->email->message($body);

上一篇: 【”吻”的相关表达 】
下一篇:javascript 获取 日期

7条评论

  1. I think, that you commit an error. Let’s discuss.

    hpixel

发表评论