I updated some data by inserting it into the fields and clicking on the update button, but validates()
is always returning false.
All the fields are filled correctly, and it does not display any error messages - validates()
just returns false.
Why?
$this->Post->set($this->data);
if ($this->Post->validates())
echo 'ok';
else
echo 'error';
See Question&Answers more detail:os