Welcome Guest, Not a member yet? Register   Sign In
Loading own classes with interfaces

Hey there

I'm moving away from dealing with associative arrays without any behaviours. This results in writing proper classes. I'm now a bit stucked with loading and instantiating them. I'm aware that there is codeigniter's load_class - function. But this will fail if my class should implement an interface, and furthermore only works when the class resides in the library-folder.

As suggested here, I could implement the __autoload - interceptor into the config-file. This does it actually, but I wanted to figure out if there might be some other ways?

Where do you keep actually your classes which are rather data-providers than functional libraries? E.g. an order-class...


Messages In This Thread
Loading own classes with interfaces - by El Forum - 12-28-2009, 08:45 AM
Loading own classes with interfaces - by El Forum - 12-29-2009, 03:54 AM

Theme © iAndrew 2016 - Forum software by © MyBB