Welcome Guest, Not a member yet? Register   Sign In
Messing with OOP in Codeigniter
#3

[eluser]Aken[/eluser]
[quote author="rjsmith" date="1360525099"]First, since you want to use CI resources in your library, you have to grab a reference to CI.[/quote]
They did that already through the __get() method.

Unless you need to create multiple instances of an object, your library is already instantiated once when you load it.

Code:
$this->load->libary('fqgallery');
// New instance of gallery object located at:
$this->fqgallery


Messages In This Thread
Messing with OOP in Codeigniter - by El Forum - 02-10-2013, 05:34 AM
Messing with OOP in Codeigniter - by El Forum - 02-10-2013, 12:38 PM
Messing with OOP in Codeigniter - by El Forum - 02-11-2013, 12:40 AM
Messing with OOP in Codeigniter - by El Forum - 02-11-2013, 05:34 AM



Theme © iAndrew 2016 - Forum software by © MyBB