Can't send email with codeigniter

$config['smtp_host'] = 'ssl://'; //change this
$config['smtp_port'] = '465';
$config['smtp_user'] = ''; //change this
$config['smtp_pass'] = '*********'; //change this
$config['mailtype'] = 'html';
$config['smtp_timeout'] = 30;     
$config['charset'] = 'utf-8';   
$config['crlf'] = "\r\n";   
$config['newline'] = "\r\n";

$message = 'Hi there';
      $email = '';
        $result = $this->email`enter code here`
        ->from("", "")
        ->reply_to("", "")
Show comments

Submit an answer

This textbox defaults to using Markdown to format your answer.

You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

Sign In or Sign Up to Answer

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

Want to learn more? Join the DigitalOcean Community!

Join our DigitalOcean community of over a million developers for free! Get help and share knowledge in Q&A, subscribe to topics of interest, and get courses and tools that will help you grow as a developer and scale your project or business.

Hi there,

What is the exact error that you get when you try to send the email?

If you have a firewall, I could suggest making sure that you have port 465 open and also test the connection to on port 465, you can do that with the telnet command:

telnet 465

Regards, Bobby

Already done but nothing changed