![]() |
AJAX Add to Cart Issue
Hi All,
I'm having a strange issue with the Ajax add to cart functionality. The add to cart function is working properly, but when the add to cart button returns to it's normal "state" after a product is added, the custom styling I've done to my select boxes goes away: http://future.thefutureforward.com/~field/product-one.html I'm using the jQuery UI-based "selectmenu" plugin to replace the select menu styles. I'm guessing it has something to do with the "ajax.widgets.add2cart.obj.prototype.cleanAddedSta te" function in the "common_files/js/ajax.add2cart.js" file, but just adding the js calls for "selectmenu" into that function doesn't work. Any thoughts on why those select boxes are losing their styling when a product is added would be much appreciated!! |
Re: AJAX Add to Cart Issue
This is happening because in here - /include/func/func.ajax.php - at the end of each function the original template is called and it replaces whatever is there on the page. I still can't figure out why it is designed that way (4 versions already), it seems unnecessary thing to do. You can either comment out lines like this
Code:
return func_display('customer/main/product_details.tpl', $smarty, false); Or replace with yoru own template |
Re: AJAX Add to Cart Issue
Steve,
That is quite odd, indeed. Commenting out that line did the trick. Thank-you SO MUCH for this tip. |
Re: AJAX Add to Cart Issue
I thought I'd add a side note to this, you can also use the ajax template call to call a different template after add to cart. Very handy if you want to pop up a continue shopping or checkout button after add to cart has been pressed.
|
All times are GMT -8. The time now is 09:35 AM. |
Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.