PHP PregMatch white space?

Mark

New member
Hi I want to allow only letters an white space to be entered into a field at the moment I have...


if(preg_match('/^[a-zA-Z]{2,25}$/i',$_REQUEST['name']))

I wondered if anyone knows how to add a white space as I want the field to accept full names like

John Smith rather than just John.

Cheers

Mark
 
Back
Top