Autofill Dashes in Phone Number

Hi all,

We have multiple forms with a text field using the phone pattern Regex. The issue here is it requires users to put the hyphens / dashes in themselves. Without that the default error is to put in a valid phone number.

image

We should be able to use an $on(change, function(value)) event in fd.rendered to validate that and insert the hyphens for them, yes?

Hello @t.sheehy,

If you need a hyphen in a phone number, I would suggest using the Masked input field type instead:
5B9E19B2-9180-4B7A-8C4C-C46515A98EC0

1 Like

Thank you! Forgot that was an option, not going to lie.

1 Like