I would like to create a form validation that checks if the
input of a certain field contains a number in a specific format.
The format should be alphabetic(one character).numeric(two
characters).numeric(three characters) ex. A.01.999
How can I achieve this with the form validation in
DreamWeaver MX?
Such a specific validation can be done by defining a "regular
expression" pattern -- but DW MX built-in "Validate Form" behaviour
regretfully doesn´t provide an "apply regular expression"
option.
You might want to give some advanced 3rd party form
validation extensions a try, some of them let you apply your own
pattern (sometimes called "mask").
> I would like to create a form validation that checks if
the input of a certain
> field contains a number in a specific format. The format
should be
> alphabetic(one character).numeric(two
characters).numeric(three characters) ex.
> A.01.999
>
> How can I achieve this with the form validation in
DreamWeaver MX?
>
> Thanks in advance!
>
> Robin Meeuwsen
>
function specialTest(inp){return
/^[A-Z]\.\d\d\.\d\d\d$/i.test(inp);}