Model refusing to insert data |
(01-09-2021, 07:21 AM)includebeer Wrote: Are you sure the data is not rejected by your validation rules? What does $model->errors() returns? This was one of my first ideas and unfortunately it was not the source of my issue, though it did give me a bit of reassurance that I'm not completely awful at this whole programming thing when I saw that they were working as intended. For the other response below yours -- I triple checked to make sure I had the exact field names defined in $allowedFields as the keys for the data coming from my POST request. It wouldn't be the first time a typo has killed me, but it's not happening here so we can rule that out too. After checking out the source code for CodeIgniter\Model, it would seem there's an unimplemented method possibly interrupting code execution, and any error this causes isn't being handled properly and thus fails silently. That's my best guess at least. https://ibb.co/ZTBscWt |
Messages In This Thread |
Model refusing to insert data - by cantinsertdata - 01-06-2021, 10:10 PM
RE: Model refusing to insert data - by berendbotje91 - 01-07-2021, 04:35 AM
RE: Model refusing to insert data - by cantinsertdata - 01-07-2021, 02:05 PM
RE: Model refusing to insert data - by demyr - 01-08-2021, 08:28 AM
RE: Model refusing to insert data - by cantinsertdata - 01-08-2021, 01:12 PM
RE: Model refusing to insert data - by includebeer - 01-09-2021, 07:21 AM
RE: Model refusing to insert data - by cantinsertdata - 01-10-2021, 12:02 AM
RE: Model refusing to insert data - by wdeda - 01-09-2021, 08:00 AM
RE: Model refusing to insert data - by berendbotje91 - 01-11-2021, 12:37 AM
RE: Model refusing to insert data - by cantinsertdata - 01-11-2021, 11:14 AM
RE: Model refusing to insert data - by paulbalandan - 01-12-2021, 09:58 AM
|