Where do I put the enye in my regex validation? Do i just put it beside regex for letters? I want to accept enyes in fname,lname, and mname.
return [
'fname' => 'required|max:255|http://regex:/^[a-zA-Z\s]+$/',
'lname' => 'required|max:255|http://regex:/^[a-zA-Z\s]+$/',
'mname' => 'max:255|alpha',
'file' => 'image|mimes:jpg,jpeg,png',
'contact_no' => 'regex:/^[-0-9\+]+$/',
'date_of_birth' => 'required|date_format:Y-m-d',
'school_id' => 'required|exists:schools,id',
'degree_id' => 'required|exists:degrees,id',
];
via Chebli Mohamed
Aucun commentaire:
Enregistrer un commentaire