Require custom field not working

General ShopSite user discussion

Require custom field not working

Postby tgavin » Tue Jul 08, 2008 12:23 pm

SS 8.3.1

I'm using a custom field, and am retrieving the data. Basically, it works.

However, I can't make it required. I mean, I can by checking the Req. checkbox, but when the field is empty in the cart and the customer clicks submit, an alert is not generated notifying the customer it's a required field.

Screen shot available: http://ginteractive.com/media/_imgs/fields.png
tgavin
 
Posts: 13
Joined: Mon Jul 09, 2007 9:05 am

Postby loren_d_c » Tue Jul 08, 2008 1:35 pm

The Custom Checkout Fields feature will not generate a JavaScript 'alert' if the required field is not provided, but it should catch this internally when the form is submitted, and instead of allowing the checkout to proceed should reload the checkout page with a message at the top telling the shopper that they didn't provide information in that required field.

Note that this error message is generated where ever the [-- ShopSiteMessages --] tag is located within the [-- DEFINE Shipping --] section of your shopping cart template, so if you are using a custom shopping cart template make sure this section contains this tag and that it is in a visible high-profile location.

If you want a JavaScript 'alert' to pop up if the shopper tries to finalize the order with this field empty, then you would have to add that check yourself via custom JavaScript added to the 'Javascript added at start of built-in CheckIt function' field in the Commerce Setup -> Order System -> Checkout menu.

-Loren
loren_d_c
 
Posts: 2572
Joined: Fri Aug 04, 2006 12:02 pm
Location: Anywhere


Return to User Forum

Who is online

Users browsing this forum: No registered users and 91 guests