Small adjustment
Posted: Wed Jun 27, 2007 7:40 am
I want to create some PHP validation for my Name input box on my form
For my Username input box, i have
This checks that the username is 5 - 20 characters in length and that a-z 0-9 _ characters are only used
How do i create a validation similar to above that only checks that the name input box is 1-20 characters in length (any characters can be used)
Thanks
For my Username input box, i have
Code: Select all
if (preg_match('/^[a-z0-9_]{5,20}$/i', $username))How do i create a validation similar to above that only checks that the name input box is 1-20 characters in length (any characters can be used)
Thanks