CodeIgniter Forums
Does it matter whether I put a MY_model.php into libraries/ or core/ ? - 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: Does it matter whether I put a MY_model.php into libraries/ or core/ ? (/showthread.php?tid=42636)



Does it matter whether I put a MY_model.php into libraries/ or core/ ? - El Forum - 06-13-2011

[eluser]snifty[/eluser]
I'm a bit confused about which is the best practice. I want to use a base model, and I've found various forks of one called codeigniter-base-model on github.

But the READMEs differ:

https://github.com/notomato/codeigniter-base-model says to put it in application/libraries.

https://github.com/jamierumbelow/codeigniter-base-model says to put it in application/core.

Is this just a matter of preference?

(I suspect it would be better to do this with a Spark, but I've had trouble with my curl's HTTPS support. Sad ).

Thanks!


Does it matter whether I put a MY_model.php into libraries/ or core/ ? - El Forum - 06-13-2011

[eluser]snifty[/eluser]
Oops, looks like application/libraries is the wrong place:

http://ellislab.com/forums/viewthread/163534/

It should go in application/core.


Does it matter whether I put a MY_model.php into libraries/ or core/ ? - El Forum - 06-13-2011

[eluser]InsiteFX[/eluser]
If the library you are extending is in system/core then it goes in application/core
If the library you are extending is in system/libraries then it goes in application/libraries

InsiteFX


Does it matter whether I put a MY_model.php into libraries/ or core/ ? - El Forum - 06-14-2011

[eluser]snifty[/eluser]
Oh, I see now, thanks!