![]() |
You must use the "set" method to update an entry. - Printable Version +- CodeIgniter Forums (https://forum.codeigniter.com) +-- Forum: CodeIgniter 4 (https://forum.codeigniter.com/forumdisplay.php?fid=28) +--- Forum: CodeIgniter 4 Support (https://forum.codeigniter.com/forumdisplay.php?fid=30) +--- Thread: You must use the "set" method to update an entry. (/showthread.php?tid=68720) |
You must use the "set" method to update an entry. - Edel - 08-16-2017 I am here again. I want to use the save method of the model class the code In my controller: PHP Code: $data = $this->request->getPost(); My Model: Code: protected $table = 'user'; the problem is the server returns "You must use the "set" method to update an entry." In the user guide the set method is used in database Builder class but not say nothing about the relationship between set and save methods. so How can I use the save method.? RE: You must use the "set" method to update an entry. - kilishan - 08-16-2017 It sounds like you haven't filled out the $allowedFields array with the columns that should be editable. RE: You must use the "set" method to update an entry. - Edel - 08-16-2017 thanks again. you're right. I thought that allowed_fields was optional. |