title: SMTP mail error in CodeIgniter : server might not be configured to send mail
body: <p>I am trying to send SMTP email using CodeIgniter, but I'm getting error in response ...</p>
  
  <p>"<strong>The following SMTP error was encountered: 0
  Unable to send email using PHP SMTP. Your server might not be configured to send mail using this method.</strong>"</p>
  
  <pre><code>User-Agent: CodeIgniter
  Date: Tue, 13 Dec 2016 07:06:56 +0000
  From: "Blabla" &lt;xxxxxxxxxxxxxx&gt;
  Return-Path: &lt;xxxxxxxxxxxxxxxxxxx&gt;
  To: xxxxxxxxxxxx
  Reply-To: "Explendid Videos" &lt;xxxxxxxxxxxxxxxxxx&gt;
  Subject: =?utf-8?Q?=54=68=69=73=20=69=73=20=61=6E=20=65=6D=61=69=6C=20=74=65=73=74?=
  X-Sender: bttvsupport@cloudlink.co.in
  X-Mailer: CodeIgniter
  X-Priority: 3 (Normal)
  Message-ID: &lt;584f9e1023f2f@xxx.co.in&gt;
  Mime-Version: 1.0
  
  
  Content-Type: multipart/alternative; boundary="B_ALT_584f9e1023f99"
  
  This is a multi-part message in MIME format.
  Your email application may not support this format.
  
  --B_ALT_584f9e1023f99
  Content-Type: text/plain; charset=utf-8
  Content-Transfer-Encoding: 8bit
  
  It is working. Great!
  
  
  --B_ALT_584f9e1023f99
  Content-Type: text/html; charset=utf-8
  Content-Transfer-Encoding: quoted-printable
  
  It is working. Great!
  
  --B_ALT_584f9e1023f99--
  </code></pre>
  
  <p>Code is </p>
  
  <pre><code>$ci = get_instance();
          $ci-&gt;load-&gt;library('email');
          $config = array();
          $config['protocol'] = "smtp";
          $config['smtp_host'] = "xxxxx";
          $config['smtp_port'] = 25;
          $config['smtp_user'] = "xxxxx"; 
          $config['smtp_pass'] = "xxxxx";
          $config['charset'] = "utf-8";
          $config['mailtype'] = "html";
          $config['newline'] = "\r\n";
  
          $ci-&gt;email-&gt;initialize($config);
  
          $ci-&gt;email-&gt;from('xxxxx', 'Blabla');
          $list = array('xxxxx');
          $ci-&gt;email-&gt;to($list);
          $this-&gt;email-&gt;reply_to('xxxxx', 'Explendid Videos');
          $ci-&gt;email-&gt;subject('This is an email test');
          $ci-&gt;email-&gt;message('It is working. Great!');
          if($ci-&gt;email-&gt;send()){echo "send";}else{echo "error ";print_r($ci-&gt;email-&gt;print_debugger());}
  </code></pre>
  
  <hr>