Validasi nomor telepon, Laravel
'phone' => 'required|regex:/(01)[0-9]{9}/'
Handsome Hamerkop
'phone' => 'required|regex:/(01)[0-9]{9}/'
'mobile' => ['required', function ($attribute, $value, $fail) use ($parameters) {
if (($value + strlen($parameters['code'])) < 15) {
$fail('Mobile number is too long');
}
}