Answers for "laravel validator requirer number float"

PHP
7

numbric validate laravel

$rules = ['Fno' => 'numeric|min:2|max:5', 'Lno' => 'numeric|min:2'];
Posted by: Guest on November-01-2020
2

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

Browse Popular Code Answers by Language