Welcome Guest, Not a member yet? Register   Sign In
Send email with sendmail or smtp?
#1

[eluser]joe_h[/eluser]
hi boys, I have a big problem with send mail from codeigniter, my mailserver smtp is over ssl port 445, I test various solutions but I don´t solve this problem.

Here the code:
Code:
// Email configuration
        $config = Array(
            'protocol' => 'smtp',
            'smtp_host' => 'xxxx',
            'smtp_port' => 465,
            'smtp_user' => [email protected]', // change it to yours
            'smtp_pass' => '.......', // change it to yours
            'mailtype' => 'html',
            'charset' => 'iso-8859-1',
            'wordwrap' => TRUE
        );

        $this->load->library('email', $config);
        $this->email->set_newline("\r\n");
        $this->email->from('[email protected]'); // change it to yours
        $this->email->to('[email protected]'); // change it to yours
        $this->email->subject('Email using Gmail.');
        $this->email->message('Working fine ! !');

        if ($this->email->send()) {
            echo 'Email sent.';
        } else {
            show_error($this->email->print_debugger());
        }

Here the errors:
Code:
A PHP Error was encountered

Severity: Notice

Message: fwrite() [function.fwrite]: send of 12 bytes failed with errno=10054 Se ha forzado la interrupción de una conexión existente por el host remoto.

Filename: libraries/Email.php

Line Number: 1846

Other information of errors:
hello:
The following SMTP error was encountered:
Unable to send data: AUTH LOGIN
Failed to send AUTH LOGIN command. Error:
Unable to send data: MAIL FROM:

from:
The following SMTP error was encountered:
Unable to send data: RCPT TO:
to:
The following SMTP error was encountered:
Unable to send data: DATA

Sorry by my English. Thank you.




Theme © iAndrew 2016 - Forum software by © MyBB