Answer the question
In order to leave comments, you need to log in
Why does PHP swear at Codeignaiter code?
Php complains about
$this->db->update('mytable', $data, array('id' => $id));
Severity: Notice --> Array to string conversion
Error: Unknown column 'Array' in 'field list'
Answer the question
In order to leave comments, you need to log in
The essence of the error is that a string data type is expected, but an array comes.
Look in the db->update() method to see what data is being received.
I can assume that the format may be something like this:
$ data - data that you write.
$this->db->update('table_name', $data, 'column_name')
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question