Welcome Guest, Not a member yet? Register   Sign In
CI case-sensitivity
#1

[eluser]Tri Dang[/eluser]
Hello everyone,

First, I must say that CI is very good for me. I use it now and then for my not-very-small web sites development. Thanks for the great product.

I have a concern about case-sensitivity (sorry, English is not my native language) of CI that I think you guys may point me to the right direction. The problem is:
-I known that CI use Camel for class names and lower_case for file names. So, if I have a model My_model, I will store it in my_model.php. To use it in my controllers, I can use either: $this->load->model('My_model') or $this->load->model('my_model') (notice the first character 'm'). But after loading, I must use the correct name with case-sensitivity. What is your prefer way of load? Class name or file name? I known that each one may have a prefer way, so I just want to see what is used more.
-But there is an exception to the above rule, that is when I load
Code:
$this->load->library('Form_validation');
  if($this->Form_validation->run() == FALSE)
  ...
I always get "Fatal error: Call to a member function run() on a non-object". But the error is not happen when I used
Code:
$this->load->library('form_validation');
  if($this->form_validation->run() == FALSE)
  ...
that means file name is prefer than class name for core library? or if I misunderstand something about CI?

Thanks in advance


Messages In This Thread
CI case-sensitivity - by El Forum - 01-14-2009, 12:15 AM
CI case-sensitivity - by El Forum - 01-20-2009, 01:25 AM
CI case-sensitivity - by El Forum - 01-20-2009, 01:41 AM
CI case-sensitivity - by El Forum - 01-20-2009, 03:20 AM
CI case-sensitivity - by El Forum - 01-20-2009, 03:40 AM
CI case-sensitivity - by El Forum - 01-20-2009, 03:49 AM



Theme © iAndrew 2016 - Forum software by © MyBB