Welcome Guest, Not a member yet? Register   Sign In
Constructor Problem
#2

[eluser]Dam1an[/eluser]
For a start, you mis spelt function for get_menu
You need to either make the CI instance a class variable, or create an instance for each function

For the first method, use
Code:
class Menu {
    var $CI;
    
    function Menu() {
        $this->CI =& get_instance();
    }
    
    function get_menu($param) {
        $this->CI->load->model('m_menu');
        ...
    }
}


Messages In This Thread
Constructor Problem - by El Forum - 06-21-2009, 03:48 AM
Constructor Problem - by El Forum - 06-21-2009, 03:52 AM
Constructor Problem - by El Forum - 06-21-2009, 04:14 AM
Constructor Problem - by El Forum - 06-21-2009, 04:18 AM
Constructor Problem - by El Forum - 06-22-2009, 06:48 AM



Theme © iAndrew 2016 - Forum software by © MyBB