Welcome Guest, Not a member yet? Register   Sign In
Model Question
#1

[eluser]napz[/eluser]
I am creating 2 model? but i keep having errors like

"Fatal error : Call to a member function resumeInfo() on a non-object in C:\xampp\htdocs\cipms\system\application\controllers\test.php on line 6 "

is it okay to create 2 model? Maybe the error is because i have 2 model.
#2

[eluser]eoinmcg[/eluser]
You can use as many models as you like in your controllers.

Make sure you're loading them:
Code:
$this->load->model('Model_name_1');
  $this->load->model('Model_name_2');

And calling the methods correctly:
Code:
$data['resume'] = $this->Model_name_1->resumeInfo();
$data['something_else'] = $this->Model_name_2->method_name();
#3

[eluser]napz[/eluser]
Thanks for the reply,

I found the problem. I am not auto loading the model name.




Theme © iAndrew 2016 - Forum software by © MyBB