![]() |
update qty cart.tpl
When the qty is updated in cart.tpl, if the qty entered is greater than the qty available the number is automatically reduced to the max number of products on hand. This is good.
But the custoemr is not notified of this. How do I add an alert box that says "The updated quantity you requested is greater than our quantity in stock. We have adjusted the quantity ordered to match the maximum quantity of this product we are able to ship" thx, Ash |
Re: update qty cart.tpl
In the template you can probably do something like
if number_in_text_box equal $product.avail then show message Not sure about exact variables available there right now. If this works note that if you have 5 items available and cutomer enter 5 or mre then 5 they will see same message so you may wanna change the message a little bit to more generic one If this doesn't work you have to edit cart.php and find the code that takes the number entered and compares to product availability |
Re: update qty cart.tpl
the href is this
href="javascript: document.cartform.submit()" Is this done by javascript. where would I FIND THIS CODE? Ash |
Re: update qty cart.tpl
This just says submit form named cartform located in current page
|
Re: update qty cart.tpl
I gave up, and sent it on to my programmer :) Couldn't figure it out.
|
Re: update qty cart.tpl
I didn't try it but just like almost everything we do you will be suprised at the end how simple it was. Probably :)
Let us know how it turns out. This should be default behaviour in xcart |
Re: update qty cart.tpl
Any update on this? I'm trying to do the same thing.
|
All times are GMT -8. The time now is 12:57 PM. |
Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.