Country and state/province fields on Forms

Richard_Wasylyn
Level 4 - Champion Alumni

Country and state/province fields on Forms

Does anyone know if you can have the state/province field set to have dependent picklists based on the country that is selected. For example, if the user selects Canada as a country, can only Canadia provinces show in the state/province field?

One step further can we have the state/province field visible only after the country is selected.

At this point I'm guessing that there isn't an easy way to do this within marketo that we'll likely need some javascript to handle this.

Does anyone have a similar set up that can provide some suggestions?
Richard Wasylynchuk
Tags (1)
14 REPLIES 14
Anonymous
Not applicable

Re: Country and state/province fields on Forms

Hey Richard,

"Dynamic States" are possible and pretty straightforward to set up. Here is a link to an article about how to do it: https://community.marketo.com/MarketoResource?id=kA650000000GtpdCAC



Anonymous
Not applicable

Re: Country and state/province fields on Forms

Hi Richard,

http://info.digital-pi.net/auto-country-state.html
It have a working example created by one of Marketo community member.


Richard_Wasylyn
Level 4 - Champion Alumni

Re: Country and state/province fields on Forms

Quick question on the basic country file that is provided in the documentation. The file has "United States::US," for each country, would the country or the two character code populate the country field in our CRM? If I take out the two character country code would that cause any issues with the drop down?
Richard Wasylynchuk
Richard_Wasylyn
Level 4 - Champion Alumni

Re: Country and state/province fields on Forms

I've managed to get the country and state/province fields working however, for some reason Newfoundland is showing up in the US state dropdown. It's also showing up in it's proper place in the Canadian provinces. Any ideas what might be going on here?
Richard Wasylynchuk
Anonymous
Not applicable

Re: Country and state/province fields on Forms

Hey Richard,

When you see "United States::US", you will see "United States" in the dropdown in the form, but once submitted, "US" will be the country. If you want "US" in the dropdown, but "United States" in your system, simply put "US::United States". If you want "US" in the dropdown and "US" in your system, simply put "US". The two colons let the system know what should be seen and what should be entered if selected. 

The easiest way to check is to copy the selections and paste in a word doc. Then, use Ctrl+f to search for "Newfoundland". My best guess is that somehow it was added twice. 

Let me know how it goes!
Katie_McKay
Level 1

Re: Country and state/province fields on Forms

I feel your pain, Richard. For me, Newfoundland shows up under the US and not under Canada. I've even tried playing with the order of provinces in a word doc and the only way to remove it from the dropdown is to remove Newfoundland altogether.
Richard_Wasylyn
Level 4 - Champion Alumni

Re: Country and state/province fields on Forms

Hi Katie,

I submitted a support ticket and it looks like the issue is with the default lists that they have posted. Here is what I got from support:

"I checked the selection options in the form for state/province and found Newfoundland::NL. I think Newfoundland is NF, I changed it, and the Landing Page seems to like it better."

We've got it working now so all you need to do is change the "NL" to "NF" and it should work.

Richard Wasylynchuk
Katie_McKay
Level 1

Re: Country and state/province fields on Forms

That did the trick! Thank you!
Anonymous
Not applicable

Re: Country and state/province fields on Forms

Hi Rajesh,

can you please upload the entire country and state list with all the javascript files here.

As,you used in the below URL :

http://info.digital-pi.net/auto-country-state.html

Because,when i upload the Australia,US and canada ,it is not working.
Please help me out this issue.
Currently,i am using FORM 1.0