Unable to send emails SMPT errors in codigniter 3
<p>This is my code, I tried smtp_port 587,465, and 25 too. But I'm unable to send an email. And my website is not SSL so I avoid <strong>ssl://smtp.googlemail.com</strong> instead of I use <strong>smtp.googlemail.com</strong> and I also tried with <strong>ssl://smtp.googlemail.com</strong></p>

<pre><code>public function email()
{
     $config = Array(
        'protocol' =&gt; 'smtp',
        'smtp_host' =&gt; 'smtp.googlemail.com',
        'smtp_port' =&gt; 465,
        'smtp_user' =&gt; '******',
        'smtp_pass' =&gt; '******',
        'mailtype'  =&gt; 'html', 
        'charset'   =&gt; 'iso-8859-1'
    );
    $this-&gt;load-&gt;library('email', $config);
    $this-&gt;email-&gt;set_newline("\r\n");

    $this-&gt;email-&gt;from('uvizag@gmail.com', 'Vizag updates');
    $this-&gt;email-&gt;to('siddharthaesunuri@gmail.com'); 
    $this-&gt;email-&gt;subject('Activation link...! Vizag updates');
    $msg = "your activation link &lt;a href='base_url'&gt;click here&lt;/a&gt;";
    $this-&gt;email-&gt;message($msg);
    $this-&gt;email-&gt;send();
    echo $this-&gt;email-&gt;print_debugger();    
}
</code></pre>

<p>How can I solve this ? can you help me please I appreciate your valuable answer</p>

<p><a href="http://i.stack.imgur.com/zLNMC.png" rel="nofollow">Please click to show my errors</a></p>

<p><strong>or</strong></p>

<pre><code>A PHP Error was encountered

Severity: Notice

Message: fwrite(): send of 6 bytes failed with errno=32 Broken pipe

Filename: libraries/Email.php

Line Number: 2172

Backtrace:

A PHP Error was encountered

Severity: Notice

Message: fwrite(): send of 6 bytes failed with errno=32 Broken pipe

Filename: libraries/Email.php

Line Number: 2172

Backtrace:

A PHP Error was encountered

Severity: Notice

Message: fwrite(): send of 6 bytes failed with errno=32 Broken pipe

Filename: libraries/Email.php

Line Number: 2172

Backtrace:

A PHP Error was encountered

Severity: Notice

Message: fwrite(): send of 6 bytes failed with errno=32 Broken pipe

Filename: libraries/Email.php

Line Number: 2172

Backtrace:

A PHP Error was encountered

Severity: Notice

Message: fwrite(): send of 6 bytes failed with errno=32 Broken pipe

Filename: libraries/Email.php

Line Number: 2172

Backtrace:

A PHP Error was encountered

Severity: Notice

Message: fwrite(): send of 6 bytes failed with errno=32 Broken pipe

Filename: libraries/Email.php

Line Number: 2172

Backtrace:

A PHP Error was encountered

Severity: Notice

Message: fwrite(): send of 6 bytes failed with errno=32 Broken pipe

Filename: libraries/Email.php

Line Number: 2172

Backtrace:

A PHP Error was encountered

Severity: Notice

Message: fwrite(): send of 6 bytes failed with errno=32 Broken pipe

Filename: libraries/Email.php

Line Number: 2172

Backtrace:

A PHP Error was encountered

Severity: Notice

Message: fwrite(): send of 6 bytes failed with errno=32 Broken pipe

Filename: libraries/Email.php

Line Number: 2172

Backtrace:

A PHP Error was encountered

Severity: Notice

Message: fwrite(): send of 6 bytes failed with errno=32 Broken pipe

Filename: libraries/Email.php

Line Number: 2172

Backtrace:

A PHP Error was encountered

Severity: Notice

Message: fwrite(): send of 6 bytes failed with errno=32 Broken pipe

Filename: libraries/Email.php

Line Number: 2172

Backtrace:

A PHP Error was encountered

Severity: Notice

Message: fwrite(): send of 6 bytes failed with errno=32 Broken pipe

Filename: libraries/Email.php

Line Number: 2172

Backtrace:

A PHP Error was encountered

Severity: Notice

Message: fwrite(): send of 6 bytes failed with errno=32 Broken pipe

Filename: libraries/Email.php

Line Number: 2172

Backtrace:

A PHP Error was encountered

Severity: Notice

Message: fwrite(): send of 6 bytes failed with errno=32 Broken pipe

Filename: libraries/Email.php

Line Number: 2172

Backtrace:

A PHP Error was encountered

Severity: Notice

Message: fwrite(): send of 6 bytes failed with errno=32 Broken pipe

Filename: libraries/Email.php

Line Number: 2172

Backtrace:

A PHP Error was encountered

Severity: Notice

Message: fwrite(): send of 6 bytes failed with errno=32 Broken pipe

Filename: libraries/Email.php

Line Number: 2172

Backtrace:

A PHP Error was encountered

Severity: Notice

Message: fwrite(): send of 6 bytes failed with errno=32 Broken pipe

Filename: libraries/Email.php

Line Number: 2172

Backtrace:

A PHP Error was encountered

Severity: Notice

Message: fwrite(): send of 6 bytes failed with errno=32 Broken pipe

Filename: libraries/Email.php

Line Number: 2172

Backtrace:

A PHP Error was encountered

Severity: Notice

Message: fwrite(): send of 6 bytes failed with errno=32 Broken pipe

Filename: libraries/Email.php

Line Number: 2172

Backtrace:

A PHP Error was encountered

Severity: Notice

Message: fwrite(): send of 6 bytes failed with errno=32 Broken pipe

Filename: libraries/Email.php

Line Number: 2172

Backtrace:

A PHP Error was encountered

Severity: Notice

Message: fwrite(): send of 6 bytes failed with errno=32 Broken pipe

Filename: libraries/Email.php

Line Number: 2172

Backtrace:

A PHP Error was encountered

Severity: Notice

Message: fwrite(): send of 6 bytes failed with errno=32 Broken pipe

Filename: libraries/Email.php

Line Number: 2172

Backtrace:

A PHP Error was encountered

Severity: Notice

Message: fwrite(): send of 6 bytes failed with errno=32 Broken pipe

Filename: libraries/Email.php

Line Number: 2172

Backtrace:

A PHP Error was encountered

Severity: Notice

Message: fwrite(): send of 6 bytes failed with errno=32 Broken pipe

Filename: libraries/Email.php

Line Number: 2172

Backtrace:
</code></pre>