I have no idea how to make validation rules for the email field. I want to accept mail id which are not from server say '@myemail.com, @yahoo.com, @outlook.com' when someone is registering. If this mail address is given it will say your mail id is not valid. what should I do??
please help me, here is my ResigterController.php
protected function validator(array $data)
{
return Validator::make($data, [
'name' => ['required', 'string', 'max:255'],
'email' => ['required', 'string', 'email', 'max:255', 'unique:users'],
'password' => ['required', 'string', 'min:8', 'confirmed'],
'mobile_no' => ['required', 'string', 'min:10'],
'company' => ['required', 'string', 'max:255'],
'username' => ['required', 'string', 'max:255', 'unique:users'],
]);
}
and I don't have email.php in my config directory.