Search
 
SCRIPT & CODE EXAMPLE
 

PHP

how to make validate error when password doesnt match with password confirm laravel

// ...

$input = Input::all();

$rules = [
    'password' => 'required|min:8',
    'password_confirmation' => 'required|min:8|same:password',
];

$messages = [
    'password_confirmation.same' => 'Password Confirmation should match the Password',
];
$validator = Validator::make($input, $rules, $messages);

if ($validator->fails()) {
    return back()->withInput()->withErrors($validator->messages());
}
// ...
Comment

PREVIOUS NEXT
Code Example
Php :: show all terms of a custom taxonomy 
Php :: laravel get current route name 
Php :: laravel migrate fresh and seed 
Php :: php filter only numbers 
Php :: php foreach reverse 
Php :: Composer detected issues in your platform: Your Composer dependencies require a PHP version "= 7.3.0". You are running 7.2.34 
Php :: Adding or Subtracting Time 
Php :: how to find datatype of a variable in php 
Php :: Syntax error or access violation: 1071 Specified key was too long; max key length is 1000 bytes (SQL: alter table `users` add unique `users_email_unique`(`email`)) 
Php :: php increase number in file by one 
Php :: php unset session variable 
Php :: Call to undefined function str_limit() laaravel8 
Php :: string replace smarty 
Php :: debug wordpress errors 
Php :: php get referrer 
Php :: how to install bootstrap in laravel 
Php :: wordpress get post id 
Php :: background image in laravel blade 
Php :: laravel keep old input 
Php :: php form action self 
Php :: woocommerce buy product skip cart 
Php :: Error Call to undefined function CodeIgniterlocale_set_default() 
Php :: laravel optimize clear 
Php :: cascade in laravel migration 
Php :: laravel dateinterval not found 
Php :: wp-config override site url 
Php :: hwo to limit char in php 
Php :: typo3 debug 
Php :: php change sting to caps 
Php :: clear all cache in laravel 
ADD CONTENT
Topic
Content
Source link
Name
1+5 =