Welcome Guest, Not a member yet? Register   Sign In
CI Case sensitivity in naming models and controllers
#1

[eluser]Dirigible[/eluser]
Quick question guys:

If I name a model login_model.php,
the class is called Login_model.php
the constructor is named login_model()

will CI correctly recognize the case differences, i.e., if I use $this->load('login_model') and $this->login_model->function(); will it work?

Thanks.
#2

[eluser]Michael Wales[/eluser]
It's OS dependent - Windows is not case sensitive, Linux is.

For the most part, name your files all lowercase and uppercase the first character of a class (within the PHP file) and you will have no problems. The constructor should be identical to the name of the class.
#3

[eluser]Dirigible[/eluser]
Appreciated.




Theme © iAndrew 2016 - Forum software by © MyBB