Autocomplete field in Web Forms for Marketers and custom Field validator

417 views Asked by At

I am using WFFM in Sitecore 7.1 , one of the requirement to have a field named Countries and want to use it as autocomplete field.

I have already loaded all the Countries in Sitecore as Sitecore Object.

I was following the Custom Credit card field , but it didn't help much.

I created custom autocomplete Field in WFFM and now i want to create custom validation for this field .

Any help..

Thanks

1

There are 1 answers

0
Alan On

To keep it simple you might want to consider a custom control like credit card and use client side JS to call your countries via sitecore web API and then do all the auto complete stuff in the js leaving all logic there.

If server side code is a preference then u can write a web service to return you the JSON objects of matching countries making your JS more simpler.

Hope this can help with some ideas.