Welcome Guest, Not a member yet? Register   Sign In
Email library won't load
#1

[eluser]thedust2010[/eluser]
This is our 3rd or 4th CodeIgniter site and we haven't had issues up until now...

In /system/application/controllers/contact.php, we have:

Code:
class Contact extends Controller {
    
    function index()
    {
        $this->load->library('email');
        print_r($this->email); exit;
    }
}

This bit of code is not adding the email class to the CodeIgniter object. Pulling up the contact page brings up the following error:

Code:
A PHP Error was encountered
Severity: Notice
Message: Undefined property: Contact::$email
Filename: controllers/contact.php
Line Number: 21

I've troubleshooted this all morning and I can determine that the "email" class is being initiated correctly in _ci_init_class (function returns true). But then it seems to lose scope. The class has only been added to the CodeIgniter object inside of _ci_init_class, but not outside. Any ideas? I've upgraded from 1.6.1 to 1.6.2 and no luck... thinking we may just use PHPMailer. I've also noticed that nothing is getting logged when I set it up to do so. Any help or opinions are much appreciated. Thanks in advance.


Messages In This Thread
Email library won't load - by El Forum - 06-16-2008, 12:15 PM
Email library won't load - by El Forum - 06-16-2008, 02:10 PM
Email library won't load - by El Forum - 06-16-2008, 02:21 PM
Email library won't load - by El Forum - 06-16-2008, 02:26 PM
Email library won't load - by El Forum - 06-16-2008, 02:28 PM
Email library won't load - by El Forum - 06-16-2008, 02:33 PM
Email library won't load - by El Forum - 06-16-2008, 02:44 PM



Theme © iAndrew 2016 - Forum software by © MyBB