Hi,
For some reason
$editor->on('writeCreate',function( $editor, $id, $values ) use ($pdo) {
print_r($pdo->query('SELECT * FROM `table` WHERE id=:id',array('id'=>$id))->results());
});
or
$editor->on('postCreate',function( $editor, $id, $values, $row ) use ($pdo) {
print_r($pdo->query('SELECT * FROM `table` WHERE id=:id',array('id'=>$id))->results());
});
prints me an empty array.
I would expect to get the data instead. $id, $values, $row already exist, but the data is not yet physically written into the DB. I need to run a query with a simple JOIN, which is impossible to execute because the row is still not there. What should I do?
Thanks,