The number of characters

Anonymous
Not applicable

The number of characters

Phone number field is Input required.

But it would be sent with only three digits entered.

We need full length of the number.

How can I set the minimum number of characters?

3 REPLIES 3
Grégoire_Miche2
Level 10

Re: The number of characters

Hi Kyoko,

You will have to use Javascript and the Form 2.0 client side API to get it done.

See http://developers.marketo.com/documentation/websites/forms-2-0/

-Greg

Anonymous
Not applicable

Re: The number of characters

Thank you very much Greg

Let me ask you some more..

Seems like I need to add the line below.

form.vals({ "Phone":"555-555-1234", "Country":"USA"});

1. The minimum number is 10 and no hyphen. How can I describe?

2. "Phone"  should be same as the field name of the form, right?

3. Is "Country" necessary? If so,what it would be like?  For example,"japan" doesn't work.

Grégoire_Miche2
Level 10

Re: The number of characters

Hi Kyoko,

I am not a JS developer, but basically, you should use a regex validation of phone number.

Yes, Marketo API will use field Names, not field labels.

-Greg