I’m having troubles getting the attributes of a model after the model->save().
I even tried getting them before the save, but i still can’t get it.
$model->attributes=$_POST['MyModel'];
$model->MyDate = date("Y-m-d H:i:s");
$MyVar = $model->MyAttribute; // this is empty
if($model->save()){
$MyVar = $model->MyAttribute; // this is empty
...
I know i could get it from the $_POST, but i think it would be better to get it from the model and i can’t understand why i get empty values.