For you first question, again you can use mutators:
public function setPasswordAttribute($value){
$this->attributes['password'] = md5($value);
}
and your second Q, laravel by default ships with a User model in your app/
directory. this model use some useful classes for authenticating, password reset and so on. By default laravel put a migration in your database/migrations
directory. If you decide to don't use laravel default User you can remove the migration, and then migrate.
You should probably move away from md5 (you could use the laravel hash methods) - https://laravel.com/docs/5.3/hashing
Sign in to participate in this thread!
The Laravel portal for problem solving, knowledge sharing and community building.
The community