title: Codeigniter send mail working in localhost but not in server
body: <h2>What I am trying</h2>
  
  <p>I am building a codeigniter application and need to send mail. My mail configuration works perfectly when I try to send mail from localhost. But its not working when host it on server.</p>
  
  <h2>Mail Config</h2>
  
  <pre><code>var $useragent      = "CodeIgniter";
  var $mailpath       = "/usr/sbin/sendmail"; // Sendmail path
  var $protocol       = "smtp";   // mail/sendmail/smtp
  var $smtp_host      = "send.one.com";       // SMTP Server.  Example: mail.earthlink.net
  var $smtp_user      = "no-reply@domain.com";        // SMTP Username
  var $smtp_pass      = "pass";       // SMTP Password
  var $smtp_port      = "25";     // SMTP Port
  var $smtp_timeout   = 60;       // SMTP Timeout in seconds
  var $smtp_crypto    = "";       // SMTP Encryption. Can be null, tls or ssl.
  var $wordwrap       = TRUE;     // TRUE/FALSE  Turns word-wrap on/off
  var $wrapchars      = "76";     // Number of characters to wrap at.
  var $mailtype       = "html";   // text/html  Defines email formatting
  var $charset        = "utf-8";  // Default char set: iso-8859-1 or us-ascii
  var $multipart      = "mixed";  // "mixed" (in the body) or "related" (separate)
  var    $alt_message         = '';       // Alternative message for HTML emails
  var $validate       = FALSE;    // TRUE/FALSE.  Enables email validation
  var $priority       = "1";      // Default priority (1 - 5)
  var $newline        = "\r\n";       // Default newline. "\r\n" or "\n" (Use "\r\n" to comply with RFC 822)
  var $crlf           = "\r\n";
  </code></pre>
  
  <p>I am getting the following error while sending from server</p>
  
  <pre><code> A PHP Error was encountered
  
   Severity: Warning
  
   Message: fsockopen(): unable to connect to send.one.com:25 (Connection timed out)
  
   Filename: libraries/Email.php
  
   Line Number: 1689
  </code></pre>
  
  <p>The application is hosted at one.com </p>