Password confirmation doesnot match?
Asked Answered
C

1

7

I am trying to using confirm password validation. I applied correct rules. But when it validates then it give me validation error like below: The password confirmation does not match. Controller

public function register(Request $req){
        $this->validate($req,[
           'Password'         =>   'required|confirmed|min:3'
          ]);

    }
Citole answered 25/3, 2020 at 19:50 Comment(4)
are you sure you sent password_confirmation inside your requestTrusty
Please show what data are you sending to this route. ($req->all())Palocz
if password_confirmation must match password, then it must also have the same validation.Smaragdine
you need password_confirmationHoodmanblind
I
14

what is your password confirmation field name because |confirmed| always work with laravel naming conversions For example, if the field under validation is password, a matching password_confirmation field must be present in the input.

is that your input name is password_confirmation ?? if not do that else comment me more code please so i can help you..

Introspection answered 26/3, 2020 at 6:26 Comment(1)
Thank you. solved. but kindly clear me that i used same name but the difference was that i used capital P and C like Password_Confirmation. Was this the problem?Citole

© 2022 - 2024 — McMap. All rights reserved.