![]() |
Model Loading problem - Printable Version +- CodeIgniter Forums (https://forum.codeigniter.com) +-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20) +--- Forum: Archived Development & Programming (https://forum.codeigniter.com/forumdisplay.php?fid=23) +--- Thread: Model Loading problem (/showthread.php?tid=3525) |
Model Loading problem - El Forum - 10-08-2007 [eluser]Xobb[/eluser] Hello, I've got the following problem with the code: File: system/application/controllers/article.php Code: class Article extends Controller File: system/application/models/article.php Code: class Articlemodel extends Model { The error: Code: A PHP Error was encountered I've installed FreakAuth and nothing else. Thank you for help in advance. Ps.: Please add the information about loading models to: Loader Manual Model Loading problem - El Forum - 11-05-2007 [eluser]jabbett[/eluser] At first glance, I noticed that your model's filename should be set differently, per the User Guide: "The file name will be a lower case version of your class name." If your model class name is Articlemodel, your filename should be articlemodel.php, not article.php. But considering you've got a library loader error, I'd start by checking your FreakAuth installation and taking up the problem with them. Model Loading problem - El Forum - 11-05-2007 [eluser]Eric Barnes[/eluser] Also I see this: Code: class Articlemodel extends Model { Which should be: Code: class Articlemodel extends Model { and: Code: $this->load->model('article', 'art'); Should be: Code: $this->load->model('articlemodel', 'art'); Model Loading problem - El Forum - 11-06-2007 [eluser]Xobb[/eluser] thank you, guys. Really, I had to load this: Code: $this->load->model('articlemodel', 'art'); |