Undefined property Cart::$Cart_model - Printable Version +- CodeIgniter Forums (https://forum.codeigniter.com) +-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20) +--- Forum: Archived General Discussion (https://forum.codeigniter.com/forumdisplay.php?fid=21) +--- Thread: Undefined property Cart::$Cart_model (/showthread.php?tid=60998) |
Undefined property Cart::$Cart_model - El Forum - 08-25-2014 [eluser]Unknown[/eluser] Hello, I've started to learn CI but I stuck at the beginning.. I following one tutorial where I must creat a Cart. What I've done is in controler/cart.php i have: Code: class Cart extends CI_Controller { In models/cart_model.php Code: class Cart_model extends CI_Model { Quote:A PHP Error was encounteredLine number 8 -> $data['cart'] = $this->Cart_model->retrieve_products(); I have found some solutions in Google but none of them working in my case. Can someone explain what is wrong here? Thank's in advance p.s. Excuse my English... Still learn it Undefined property Cart::$Cart_model - El Forum - 08-25-2014 [eluser]InsiteFX[/eluser] In your index method Cart_model should be lowercase cart_model Undefined property Cart::$Cart_model - El Forum - 08-25-2014 [eluser]Unknown[/eluser] Oh, this case sensitivity. Thank's for your help! |