I have some problems to use my own classes using codeigniter. If it is not an error, it always says that the class can not be loaded. For example, I created a class "Student" with atributes and only getter and setter methods, so I need to use that class in a model to return an array of "Students"(what I can not do with "load->library") or to receive a "Student" for storing it, and I also need that class for my controller to do something with "Student"
I am working in Windows and I don't want to use an ORM because de app is not big.
I also want to do something like this in my model:
while(something){
$arr[] = new Student();
}
return $arr;
What can I do? I will be grateful for your answers.
(PD: I'm sorry, I am not an English speaker)
I solved it The only thing I had to do was create the file Student.php (where the class Student is) and put it on Libraries, after that:
$this->upload->library("Student.php");
and after that we can "instanciar" the class .