laravel validation alphanumeric with spaces code example
Example 1: laravel validation alphanumeric with spaces
[
'field' => 'regex:/[a-zA-Z0-9\s]+/',
]
Example 2: laravel validation alphanumeric with spaces
[
'field' => 'regex:/^[a-zA-Z0-9\s]+$/',
]
Example 3: laravel validation alphanumeric with spaces
[
'field' => 'regex:[a-zA-Z0-9\s]+',
]