how can you auto fill the province/state and country in a form field
how can you auto fill the province/state and country in a form field
I have a little JS I use to autofill state and country, then I hide country because we almost always sell in just the US.
$('.State').parent().children().val("New York");
$(".Country").parent().children().val("USA");
$(".Country").parent().children().css('display', 'none');
Because we sell in the US primarily, I also have some code that changes the label to just state or province.
/* Hide Country field in the address field */
$(document).ready (function () {
$(".Country").parent().children().css('display', 'none');
});
/* Change label of address field input box. "State" has been changed to "Province".*/
$(document).ready (function () {
$(".State").siblings().text('State');
});