What’s the best way to do this? Thx!
What’s the best way to do this? Thx!
In your controller
<?php
if(!$model->validate()){ // or !$model->save() depending on what do you want to do
$model->password = "";
}
?>
use $model->password = ‘’;
instead of $model->password = "";
php tip and tricks, you will gain on performances
“” try to seek for php variables