![]() |
models and libraries - Printable Version +- CodeIgniter Forums (https://forum.codeigniter.com) +-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20) +--- Forum: Archived General Discussion (https://forum.codeigniter.com/forumdisplay.php?fid=21) +--- Thread: models and libraries (/showthread.php?tid=35162) |
models and libraries - El Forum - 10-20-2010 [eluser]Unknown[/eluser] hi, im still a newbie so pardon my question, i was wondering whats the clear difference between models and libraries? is it best practice if i load a model in another model? or is this a sign that i should put this functionality into the library? models and libraries - El Forum - 10-21-2010 [eluser]WanWizard[/eluser] Technically, there is no difference. From an MVC point of view, libraries contain your reusable methods, models the methods that deal with I/O. There's nothing against using models in other models. If you use an ORM for example, a model is mapped to a table, so you will always use models in models... |