How to Capture Phone Number Correctly?

I’ve created a custom form for my site. I have a field for people to enter their phone numbers. I have set the input type to “Phone Number” However, the dataset is capturing it like this:

It’s removing the 0’s from the beginning of the number also. Is there anyway to save the data as the client is entering it and remove the commas?

Thanks in advance!

1 Like

hi Hanna,

Change the collection field to Text instead of Number. It should solve the issue.

1 Like

This does not work for me. Any other suggestions?

It does it even though I changed the field to text. How can I fix it?

Hi Stacy,

Notice that Ido said to change the “collection field”. He was referring to changing the field type in the collection area.

After you have changed the field type, you’re not done yet. You will have to go through the existing records one-by-one and do the following. Maybe there is a quicker way to do it in the collection editor, but I haven’t seen it.

1 Like

Thank you so much! :slight_smile:

Use a regular expression to validate the phone number input and ensure it matches the desired format.