2016-04-07 23 views
3

Bu, HTML e-postası göndermek için kullanıyorum ancak düzgün çalışmıyor. Sadece ham html kodu e-postada gösterilir.html e-posta codeigniter içinde gönderilmez

$this->load->library('email'); 
$config['protocol'] = 'smtp'; 
$config['mailtype'] = 'html'; 
$config['crlf'] = "\r\n"; 
$config['wordwrap'] = TRUE; 
$config['newline'] = "\r\n"; 
$config['validate'] = FALSE; 
$this->email->initialize($config); 
+0

hata mesajı nedir:

 $emailID = $this->input->post('email'); $name = $this->input->post('name'); $this->load->library('email'); $config['protocol'] = 'smtp'; $config['mailtype'] = 'html'; $config['crlf'] = "\r\n"; $config['wordwrap'] = TRUE; $config['newline'] = "\r\n"; $config['validate'] = FALSE; $this->email->set_newline("\r\n"); $this->email->from($emailID,$name); $this->email->to('[email protected]'); $this->email->subject('Email Testing'); $this->email->message('from clientside mail'); $this->email->send(); $message = $this->load->view('emailfile/file','',TRUE); $this->load->library('email', $config); $this->email->from($emailID,$name); $this->email->to($emailID,$name); $this->email->subject('Email Testing'); $this->email->message($message); $this->email->send(); //echo $this->email->print_debugger(); 

+0

CI istemcinizdeki e-postanız Gmail kullanıyorsa, ayarda izin vermeyi unutmayın. Veya kendi @ web sitenizi kullanmaya çalışıyorsanız, kodunuzun gerçekten çalıştığından emin olmak için şimdi Gmail'i kullanmayı deneyin. Bazen web barındırma e-posta sunucunuz bozuldu – AchmadJP

cevap

1

$this->email->initialize($config); ekle? Bunu ekleyebilir misin lütfen?
+0

Çok teşekkürler dostum. –