close ad
Install the LAtest Updates to Work with CC 2017 and CC 2018
open ad
View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

rating

eCart 6 Checkout page State and Country issue

Thread began 2/12/2014 1:35 pm by phil287111 | Last modified 3/04/2014 12:34 pm by Jason Byrnes | 303 views | 4 replies |

phil287111

eCart 6 Checkout page State and Country issue

When filling out the Billing and/or Shipping addresses for countries other than the United States on the Checkout page the 'State' field is still required. It gets blanked out once a country other than the US is selected, but the validation pop-up bubble still comes up requesting to 'Please select your state'. Is there a setting somewhere to fix this or is it a bug?

Sign in to reply to this post

Jason ByrnesWebAssist

I'll need to troubleshoot directly, see the private message section.

Sign in to reply to this post

phil287111

See PM

Sign in to reply to this post

phil287111

I never got an answer to this and I have potential international orders on my client's site. Shouldn't the 'State' field not be required for countries other than the US and Canada? The Checkout page won't process the order with a blank 'State' field. Also, is there an option to add the other 4 digits of a Zip code?

Sign in to reply to this post

Jason ByrnesWebAssist

Sorry, I have logged this as a bug to be corrected in a future update.

to work around it for now, update the webassist/ecart/checkout/js/paymentoptions.js file and comment the "stateInput.setAttribute("required","required");" line in the following function:

if (CurState.tagName !== "INPUT") {
if (!document.getElementById("State"+index+"_Hidden")) {
var stateInput=document.createElement("input");
stateInput.setAttribute("type","text");
stateInput.setAttribute("name","State"+index+"_Hidden");
stateInput.setAttribute("id","State"+index+"_Hidden");
stateInput.setAttribute("title","Please enter your state");
stateInput.setAttribute("tabindex",CurState.getAttribute("tabindex"));
stateInput.setAttribute("class","formTextfield_Large");
//stateInput.setAttribute("required","required");
stateInput.style.display = "none";
CurState.parentNode.appendChild(stateInput);
}




and on the confirm page, remove the server validation code for the state fields, they will look similar to::
$WAFV_Errors .= WAValidateRQ((isset($_POST["State_2"])?$_POST["State"]:"") . "",true,16);

$WAFV_Errors .= WAValidateRQ((isset($_POST["State_2"])?$_POST["State_2"]:"") . "",true,16);

Sign in to reply to this post

Build websites with a little help from your friends

Your friends over here at WebAssist! These Dreamweaver extensions will assist you in building unlimited, custom websites.

Build websites from already-built web applications

These out-of-the-box solutions provide you proven, tested applications that can be up and running now.  Build a store, a gallery, or a web-based email solution.

Want your website pre-built and hosted?

Close Windowclose

Rate your experience or provide feedback on this page

Account or customer service questions?
Please user our contact form.

Need technical support?
Please visit support to ask a question

Content

rating

Layout

rating

Ease of use

rating

security code refresh image

We do not respond to comments submitted from this page directly, but we do read and analyze any feedback and will use it to help make your experience better in the future.

Close Windowclose

We were unable to retrieve the attached file

Close Windowclose

Attach and remove files

add attachmentAdd attachment
Close Windowclose

Enter the URL you would like to link to in your post

Close Windowclose

This is how you use right click RTF editing

Enable right click RTF editing option allows you to add html markup into your tutorial such as images, bulleted lists, files and more...

-- click to close --

Uploading file...