app/Http/Controllers/Auth/AuthController.php
/**
     * Get a validator for an incoming registration request.
     *
     * @param  array $data
     * @return \Illuminate\Contracts\Validation\Validator
     */
Get a validator for an incoming registration request.
@param  array $data
@return \Illuminate\Contracts\Validation\Validator
Get a validator for an incoming registration request . @param array $data @return \ Illuminate \ Contracts \ Validation \ Validator
protected function validator(array $data)
    {
        $messages = [ 
            'name.required' => 'Введите имя!',
            'email.required' => 'Введите email или логин!',
            'email.unique' => 'Email уже занят!',
            'pass.required' => 'Введите пароль!',
            're_pass.required' => 'Введите пароль повторно!',
            're_pass.same' => 'Подтверждение пароля не верно!'
        ];
        return Validator::make($data, [   
            'name' => 'required|max:50',
            'email' => 'required|email|max:50|unique:users',
            'pass' => 'required|min:3|max:50',
            're_pass' => 'required|same:pass',
        ],$messages);
    }
protected function validator ( array $ data ) { $ messages = [ 'name.required' => 'Введите имя!', 'email.required' => 'Введите email или логин!', 'email.unique' => 'Email уже занят!', 'pass.required' => 'Введите пароль!', 're_pass.required' => 'Введите пароль повторно!', 're_pass.same' => 'Подтверждение пароля не верно!' ] ; return Validator :: make ( $ data , [ 'name' => 'required|max:50' , 'email' => 'required|email|max:50|unique:users' , 'pass' => 'required|min:3|max:50' , 're_pass' => 'required|same:pass' , ] , $ messages ) ; }
Get a validator for an incoming registration request.
Get a validator for an incoming registration request .
//validation message //validation registration form