Answers for "decimal validation laravel"

PHP
1

laravel validation types for float

//For float, must use numeric validator

/**
  * Get the validation rules that apply to the request.
  *
  * @return array
 */
public function rules()
{
  return [
    'field' => 'numeric'
  ];
}
Posted by: Guest on January-14-2021
0

laravel validation digits

'last4digits' => 'digits:4'
Posted by: Guest on July-27-2021

Browse Popular Code Answers by Language