Welcome Guest, Not a member yet? Register   Sign In
Custom Library Problem [solved]
#1

[eluser]n8m[/eluser]
Hi,

I've got a problem writing my own Libraries. Here's my Class:

Code:
class Aclass{
    
    function Aclass()
    {
    $CI=& get_instance();
    $CI->load->library('session');
        

    }
    
    function checksessionid()
    {

        $session_id = $CI->session->userdata('session_id');
        echo $session_id;
    }

}

The funny thing is, that it works when I put the Constructor lines into the method. Where's the error?

Thanks for your help
n8m


Messages In This Thread
Custom Library Problem [solved] - by El Forum - 10-23-2007, 04:41 AM
Custom Library Problem [solved] - by El Forum - 10-23-2007, 05:50 AM
Custom Library Problem [solved] - by El Forum - 10-23-2007, 06:01 AM



Theme © iAndrew 2016 - Forum software by © MyBB