Email Library smtp_auth Issue |
[eluser]Unknown[/eluser]
Found a small 'bug' (more of a consistency issue) in the Email library in 1.6.2 (may have existed in earlier versions too). The "_smtp_auth" variable is only set if the username and password has been passed to the contructor, not if its passed to the "initialize" method as can be expected. Broken Example: (does not try to auth with the smtp server) Code: $this->load->library('email'); Working Example: (auths with the smtp server perfectly) Code: $config['protocol'] = 'smtp'; From what I can find, you only set the '_smtp_auth' variable in the CI_Email constructor using this line of code: Code: $this->_smtp_auth = ($this->smtp_user == '' AND $this->smtp_pass == '') ? FALSE : TRUE; If you try to initialize after construction with the login details, they are ignored since '_smtp_auth' in not set anywhere else. Minor annoyance, but would be easy enough to fix and save the next guy 30 min of head scratching. |
Messages In This Thread |
Email Library smtp_auth Issue - by El Forum - 05-28-2008, 02:28 PM
Email Library smtp_auth Issue - by El Forum - 05-28-2008, 09:30 PM
Email Library smtp_auth Issue - by El Forum - 05-29-2008, 03:34 PM
Email Library smtp_auth Issue - by El Forum - 05-29-2008, 06:46 PM
|