library issue - Printable Version +- CodeIgniter Forums (https://forum.codeigniter.com) +-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20) +--- Forum: Archived Development & Programming (https://forum.codeigniter.com/forumdisplay.php?fid=23) +--- Thread: library issue (/showthread.php?tid=42318) |
library issue - El Forum - 06-03-2011 [eluser]regal2157[/eluser] Hey everyone, I have a controller, and in the constructor, I call a library. I then try to use a method inside it, but I get thrown the error: Quote:Fatal error: Call to undefined method stdClass::createLog() in /usr/apps/webdata/sandbox/application/controllers/admin.php on line 11 Here is my controller (part that calls the library, in the construct): Code: $this->load->library('Regal_log'); PHP does see the class methods, as the print_r returns: Quote:Array ( [0] => __construct [1] => index [2] => createLog [3] => Log ) Any ideas? I am totally lost on this one. :/ I can run the class outside of CI with not a problem.. library issue - El Forum - 06-03-2011 [eluser]Jaketoolson[/eluser] Unless we're both over-looking the same thing, this should work! Let's see Regal_log class, constructor, and createLog code. library issue - El Forum - 06-03-2011 [eluser]regal2157[/eluser] Code: <?php library issue - El Forum - 06-03-2011 [eluser]danmontgomery[/eluser] Code: $this->regal_log Code: $this->Regal_log library issue - El Forum - 06-03-2011 [eluser]regal2157[/eluser] noctrum, you're a genious. all the hours... and I just had to change R to r.. thanks! |