![]() |
Modular Separation - PHP5 (Modules) - Printable Version +- CodeIgniter Forums (https://forum.codeigniter.com) +-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20) +--- Forum: Archived Libraries & Helpers (https://forum.codeigniter.com/forumdisplay.php?fid=22) +--- Thread: Modular Separation - PHP5 (Modules) (/showthread.php?tid=20208) |
Modular Separation - PHP5 (Modules) - El Forum - 02-28-2010 [eluser]theprodigy[/eluser] I have both the MY_Controller and MY_Model in the application/libraries folder (so that all controllers and models regardless of in a module or not can access them). So, CI should be picking these up, but it's only picking up the Controller extension. The controller and model accessing these extensions are in a module. The controller extending MY_Controller works as expected. The Model extending MY_Model throws a 'not found' error on the model trying to extend it (it finds the model, but not the MY_Model it is extending). When I change the model extender to MX_Model (file name, class name, and extends declaration), it works as expected. Modular Separation - PHP5 (Modules) - El Forum - 02-28-2010 [eluser]wiredesignz[/eluser] Extending MY_Model works perfectly fine here. Modular Separation - PHP5 (Modules) - El Forum - 02-28-2010 [eluser]wiredesignz[/eluser] Modular Separation PHP5 has been updated and version 1.11 is now attached to the first post of this thread. Modular Separation - PHP5 (Modules) - El Forum - 02-28-2010 [eluser]hugle[/eluser] Hello downloaded version 1.10, installed, and after refresh, I spoted that 1.11 is already here, so downloaded the new one ![]() ![]() thanks wiredesignz Modular Separation - PHP5 (Modules) - El Forum - 02-28-2010 [eluser]theprodigy[/eluser] ok, not sure why it's not working for me. folder structure (only relevant structure showing): Quote:application Modular Separation - PHP5 (Modules) - El Forum - 02-28-2010 [eluser]theprodigy[/eluser] I just thought about it. Maybe it's the way I'm loading my models. I have the constructor of my MY_Controller loading the models. Is it possible that MY_Model just isn't loaded yet? My MY_Controller constructor looks like this: Code: public function __construct() Modular Separation - PHP5 (Modules) - El Forum - 03-01-2010 [eluser]Phil Sturgeon[/eluser] [quote author="wiredesignz" date="1267418263"]Modular Separation PHP5 has been updated and version 1.11 is now attached to the first post of this thread.[/quote] Any change you could maintain a changelog? I'm glad this is actively developed but I dont like updating just for the sake of it. :-) Modular Separation - PHP5 (Modules) - El Forum - 03-01-2010 [eluser]wiredesignz[/eluser] Only one change to load->database() to match the HMVC update. You know how to run a diff Phil. ![]() Modular Separation - PHP5 (Modules) - El Forum - 03-01-2010 [eluser]Phil Sturgeon[/eluser] HA cheeky bastard. Of course I ran a diff before committing the change, would be nice for at least a sentence saying "fixed bug a but doing thing b" when you announce a new version. :-P Modular Separation - PHP5 (Modules) - El Forum - 03-03-2010 [eluser]theprodigy[/eluser] ok, I stopped loading the models in the MY_Controller constructor and I am still getting "Fatal error: Class 'MY_Model' not found in path/to/my/model.php on line 8". Please enlighten me on how to get this to work. Thanks |