moorland 发表于 2009-3-13 22:22:18

关于使用CI 的 Email类的问题

我想知道在本地是否可以使用Email类?
我在控制器里这样写,好象不运行啊,是否需要特殊的配置?

   $this->load->library('email');
   $this->email->from('aa@hotmail.com');
   $this->email->to('bb@hotmail.com');
   $this->email->subject('Email Test');
   $this->email->message('Testing the email class.');
   $this->email->send();

Hex 发表于 2009-3-14 21:20:22

请问是怎么配置的 Email 类?

moorland 发表于 2009-3-16 18:24:25

现在好用了, 我是这样配置的,但是不知道是否正确

var        $useragent                = "CodeIgniter";
var        $mailpath                = "/usr/sbin/sendmail";        // Sendmail path
var        $protocol                = "smtp";        // mail/sendmail/smtp
var        $smtp_host                = "smtp.ifrancepro.com";                // SMTP Server.Example: mail.earthlink.net
var        $smtp_user                = "我的mail";                // SMTP Username
var        $smtp_pass                = "我的密码";                // SMTP Password
页: [1]
查看完整版本: 关于使用CI 的 Email类的问题