Is there away to setup a field to receive phone number?
Phone number field
-
- User
- Posts: 980
What's the trouble?
Phone number is just an INT datatype, right?
Please explain more.
-
- User
- Posts: 9381
sagmag wrote:
But where and how will I put the regex so that the validation can be done
on client and server. If there is an error on client the red color on the
edges of the fields must be shown?
- Enable the option "Client-side (JavaScript)" in [PHP] -> [General Options] -> [Validation].
- Set up [Edit Tag] of the field as "Text".
- In [Edit Tag] -> [Validation] -> [Validate] as "Regular Expression".
- Enter your expression in [Argument (client side)].
- Enter your error message.
You can also use [Client Script] -> [Form_CustomValidate] of the Edit Page or Add Page to validate the field.
Read help file topic: "Server Events and Client Scripts" -> "Client Scripts" -> "Form_CustomValidate" for more information.