codeIgniter中发送邮件的调用方法
2016-09-30 14:13
281 查看
function send_mail($subject,$message,$attachFile) { $this->load->library('email'); $config['protocol'] = 'smtp'; $config['smtp_host'] = 'ssl://smtp.126.com'; $config['smtp_user'] = 'your email account username'; $config['smtp_pass'] = 'your email account password'; $config['mailtype'] = 'html'; $config['validate'] = true; $config['priority'] = 1; $config['crlf'] = "\r\n"; $config['smtp_port'] = 465; $config['charset'] = 'utf-8'; $config['wordwrap'] = TRUE; $this->email->initialize($config); $this->email->from('your email account username', 'your name'); //发件人 $this->email->to($this->mailTo); $this->email->subject($subject); $this->email->message($message); $this->email->attach($attachFile); $ret = $this->email->send(); var_dump($attachFile,$ret); echo $this->email->print_debugger(); }
相关文章推荐
- CodeIgniter使用smtp服务发送html邮件的方法
- codeigniter发送邮件并打印调试信息的方法
- 在iOS开发中,经常需要调用其它App,如拨打电话、发送邮件等。UIApplication:openURL:方法是实现这一目的的
- Codeigniter发送邮件的方法
- Intent机制及详解-调用系统功能,邮件发送方式,各种文件打开方法
- PHP调用Mailgun发送邮件的方法
- C#调用Outlook2003发送邮件时,避免弹出安全确认对话框的方法
- CodeIgniter使用smtp服务发送html邮件的方法
- php mailer类调用远程SMTP服务器发送邮件实现方法
- iOS调用其它App,如拨打电话、发送邮件等。UIApplication:openURL:方法是实现这一目的的
- PHP 调用Mailgun发送邮件方法总结
- php mailer类调用远程SMTP服务器发送邮件实现方法
- c++调用mapi发送邮件的方法
- Codeigniter使用Email进行SMTP发送邮件方法
- php发送邮件方法二2.(SMTP传输SMTP类调用发送)
- 实现发邮件方法,随机返回失败成功,50个线程同时调用sendEmail发送1000封邮件,统计发送失败和成功的个数
- 大文件通过邮件发送的绝佳新方法
- 发送邮件的几种方法
- WinForm 下调用 OutLook 发送邮件
- delphi调用OUTLOOK发送DBGRID中的数据(注意不是OUTLOOK EXPRESS ),带显示发送邮件界面。