[checkout] Hitting "return" empties the cart
picdude
Joined: 2006-06-13
Posts: 176 |
Posted: Fri, 2013-04-19 18:22 |
Gallery URL = http://www.photosbybailini.com/g2/main.php Hello, While tweaking my checkout for the upcoming season, I noticed that after adding an item to the cart and selecting a product, if someone (a customer) hits "return" after entering a quantity, it empties the cart. Is there a way of changing this so that hitting "return" updates the cart instead of emptying it? My gut is telling me that this is simply due to the position of the buttons at the bottom. If "save changes" was before "empty cart", might it work? Can I swap the placement of these buttons...?? Thanks! |
|
Posts: 8339
so is the empty/reset cart button highlighted by default?
-s
________________________________
All New jQuery Minislideshow for G2/G3
Posts: 176
That's what I'm guessing, suprsidr, but it's not obvious by looking at it.
The buttons along the bottom right of the basket are (from l-r) "empty cart", "save changes", and "continue to checkout". The "continue shopping" button is below those three. I think the "empty cart" button is the default. Can the default be changed to "save changes"?
Posts: 8339
It would be best to set an onChange event on the select product action to highlight the save changes button.
I'm on vacation in the Caribbean ATM if you cannot figure it out by yourself I can help next week.
-s
________________________________
All New jQuery Minislideshow for G2/G3
Posts: 176
Enjoy your vacation!
Since I don't have a clue what you're talking about, I'll be in touch next week.
I'd like to revisit the T&C thing that we talked about last year too.
Thanks!
Posts: 27300
Correct me if im wrong suprsidr, but I thought that the first submit button in the form is the default "enter" button?
I guess some JS solution would work but I think if moving the button in the template should work as well.
picdude try:
gallery2/modules/checkout/templates/Select.tpl
move
to just below
<table class="checkoutButtonTable" width="100%">
Should make the 'continue shopping' button be the default leaving the carts contents.
Enjoy the sun and sand.
Dave
_____________________________________________
Blog & G2 || floridave - Gallery Team
Posts: 176
Success!!
I found the "button" section in that template you directed me to, floridave, and just moved the "save changes" line to the top.
Like this:
{* ----------- Buttons ----------- *}
<div class="gbBlock">
<table class="checkoutButtonTable" width="100%">
<tr>
<td align="right">
<input type="submit" class="inputTypeSubmit checkoutButton checkoutSaveButton" name="{g->formVar var="form[action][savechanges]"}" value="{g->text text="Save Changes"}"/>
<input type="submit" class="inputTypeSubmit checkoutButton checkoutEmptyButton" name="{g->formVar var="form[action][emptycart]"}" value="{g->text text="Empty Cart"}"/>
<input type="submit" class="inputTypeSubmit checkoutButton checkoutContinueButton1" name="{g->formVar var="form[action][continue]"}" value="{g->text text="Continue to Checkout"}"/>
Easy as pie once I knew which template to modify. Couldn't find it on my own...
Thanks floridave and suprsidr for your help!!