$config['protocol']='smtp';
$config['smtp_host']='smtp.163.com';//163服务器,之前用了qq服务器死活发不出去,不知道什么原因,可以自己探索
$config['smtp_user']='18730261183@163.com';//你的邮箱账号
$config['smtp_pass']='mima';//你的邮箱密码
$config['smtp_port'] = 25;//端口
$config['wordwrap'] = TRUE;
$config['mailtype'] = 'html';
$config['charset'] = 'utf-8';
$config['priority'] = 1;
$config['validate'] = TRUE;
$this->load->library('email');
$this->email->initialize($config);
//$this->email->from($_POST['sendfrom'],'我是发件人') //发件人 $this->email->to($_POST['sendto']);//收件人 $this->email->subject($_POST['topic']);//主题 $this->email->message($_POST['content']);//正文
$this->email->from('18730261183@163.com', '');
$this->email->to('wen1750686723@qq.com');
// $this->email->cc('another@another-example.com');
// $this->email->bcc('them@their-example.com');
$this->email->subject('ceshi');
$this->email->message('Testing the email class.');
$this->email->send();