php - Codeigniter email class not working -


i tried code below. @ 1 time code working fine. able send emails. after few minutes, when tried again without changing anything, error message unable send email using php mail(). server might not configured send mail using method.

i dont know whats wrong. lately facing lot of similar bugs codeigniter.

public function email($message = null, $subject=null, $email=null){         if(!isset($email)){             $to = $this->session->userdata('email');         }else{             $to = $email;         }         $this->load->library('email');           $this->email->from('noreply@mydomain.com', 'mydomain');         $this->email->to($to);           $this->email->subject($subject);         $this->email->message($message);              $this->email->send();     } 

i face problem , work hard , find solution this

just little change in email config working 100%


 $config['protocol'] = 'ssmtp';  $config['smtp_host'] = 'ssl://ssmtp.gmail.com'; 

Comments

Popular posts from this blog

Change php variable from jquery value using ajax (same page) -

Pull out data related to my apps from Android Play Store and iOS App Store -

How can I fetch data from a web server in an android application? -