I've come across a bug. When I have the cart page open and have, for example, 3 products (each with a quantity of 1 item) in the cart the cart icon in the menu bar shows 3 items. That's good.
If I remove a product completely (clicking on the black cross to the left of the product), the product is removed and the cart icon in the menu bar refreshes correctly to show 2 items in the cart. That's good.
If I then change the quantity of one of the products from 1 to any other quantity and click on the 'Update Cart' button the prices update correctly but the cart icon in the menu bar does not refresh and still shows 2 items (ie it is not refreshing). That's not correct.
If I click on a menu link to take me to another page the cart icon in the menu bar refreshes and displays the correct quantity of items.
How can I/we fix this so that clicking on '+' or '-' or entering a new quantity for an item and then clicking the 'Update Cart' button refreshes the menu so that the cart icon refreshes too?
Attached is a screenshot showing 3 items in the cart (and the prices updated) but with the mini cart menu icon still showing 2 items.
Download this file and replace it in this directory (of the theme): /assets/js/
If you don't see the change immediately, please hard-refresh your browser (CTRL/CMD+R) because it takes longer to load the changes, as they are saved in browser cache. Another option is to open new private/incognito window and try if it works.
I've uploaded the code to our current test site (http://test.booklet.ro). I've made sure to turn off server side caching (varnish) too for good measure.
The new code doesn't appear to have made any difference unfortunately - I've tested in numerous browsers and on mobile/tablet. The only time that the number next to the cart icon displays correctly is when I manually do a Ctrl + R and then the whole page is refreshed. Perhaps there's a way to change the functionality of the "Update Cart" button to perform a Ctrl + R?
You'll see in the attached screenshot that the number of items in the cart has been increased from 4 to 6 by clicking on the '+' twice. The 'Update Cart' button was then pressed which brings up the "Cart Updated" message in the green banner. The cart icon still displays 4 items instead of 6 though.
Just to confirm that if a product/line is removed completely by clicking on the black circle next to the product/line then the number in the cart icon updates correctly (ie a full refresh/recalc is performed).
It's only when a quantity of a product is changed and the "Update Cart" button is pressed that the cart icon fails to refresh to match the new quantity.
Download this file and replace it in this directory (of the theme): /assets/js
If you don't see the change immediately, please hard-refresh your browser (CTRL/CMD+R) because it takes longer to load the changes, as they are saved in browser cache. Another option is to open new private/incognito window and try if it works.
Thanks for the new code. I've tested on my Windows laptop and on my iPad and it works on your link but still not on our site at http://test.booklet.ro.
I've tested also on our "base" site http://v00.booklet.ro which Ylli kindly installed for us and the same issue exists there too.
Would it help if I gave you the WP Admin & FTP details for http://test.booklet.ro and perhaps you could take a look for us to see if there's anything obvious which is preventing this from working like it does on your site?
Perfect! I confirm it's now working - many thanks for that. I can see your new aurum-custom.min.js file in the wp-content/themes/aurum/assets/js directory alongside the aBeoTR.js file you sent us previously.
Hi Guys
I've come across a bug. When I have the cart page open and have, for example, 3 products (each with a quantity of 1 item) in the cart the cart icon in the menu bar shows 3 items. That's good.
If I remove a product completely (clicking on the black cross to the left of the product), the product is removed and the cart icon in the menu bar refreshes correctly to show 2 items in the cart. That's good.
If I then change the quantity of one of the products from 1 to any other quantity and click on the 'Update Cart' button the prices update correctly but the cart icon in the menu bar does not refresh and still shows 2 items (ie it is not refreshing). That's not correct.
If I click on a menu link to take me to another page the cart icon in the menu bar refreshes and displays the correct quantity of items.
How can I/we fix this so that clicking on '+' or '-' or entering a new quantity for an item and then clicking the 'Update Cart' button refreshes the menu so that the cart icon refreshes too?
Attached is a screenshot showing 3 items in the cart (and the prices updated) but with the mini cart menu icon still showing 2 items.
Many thanks! :)
Clive
Hi Clive,
Download this file and replace it in this directory (of the theme): /assets/js/
If you don't see the change immediately, please hard-refresh your browser (CTRL/CMD+R) because it takes longer to load the changes, as they are saved in browser cache. Another option is to open new private/incognito window and try if it works.
This will fix the issue.
Hi Arlind
I've uploaded the code to our current test site (http://test.booklet.ro). I've made sure to turn off server side caching (varnish) too for good measure.
The new code doesn't appear to have made any difference unfortunately - I've tested in numerous browsers and on mobile/tablet. The only time that the number next to the cart icon displays correctly is when I manually do a Ctrl + R and then the whole page is refreshed. Perhaps there's a way to change the functionality of the "Update Cart" button to perform a Ctrl + R?
You'll see in the attached screenshot that the number of items in the cart has been increased from 4 to 6 by clicking on the '+' twice. The 'Update Cart' button was then pressed which brings up the "Cart Updated" message in the green banner. The cart icon still displays 4 items instead of 6 though.
Many thanks
Clive
Hi Arlind
Just to confirm that if a product/line is removed completely by clicking on the black circle next to the product/line then the number in the cart icon updates correctly (ie a full refresh/recalc is performed).
It's only when a quantity of a product is changed and the "Update Cart" button is pressed that the cart icon fails to refresh to match the new quantity.
Many thanks
Clive
Hi Clive,
I am not sure why it doesn't work for you. I have tested it and it is working here:
http://themes.laborator.co/aurum/fashion/cart/
Can you also replace this file on assets/js/:
Download this file and replace it in this directory (of the theme): /assets/js
If you don't see the change immediately, please hard-refresh your browser (CTRL/CMD+R) because it takes longer to load the changes, as they are saved in browser cache. Another option is to open new private/incognito window and try if it works.
And it should work this time.
Hi Arlind
Thanks for the new code. I've tested on my Windows laptop and on my iPad and it works on your link but still not on our site at http://test.booklet.ro.
I've tested also on our "base" site http://v00.booklet.ro which Ylli kindly installed for us and the same issue exists there too.
Would it help if I gave you the WP Admin & FTP details for http://test.booklet.ro and perhaps you could take a look for us to see if there's anything obvious which is preventing this from working like it does on your site?
Many thanks!
Clive
Hi Clive,
Sure, that would help me replace the file by myself. Just give me the WP or FTP credentials of the respective site and I'll take care of this issue.
You are always welcome.
Hi Clive,
I have managed to fix this issue by replacing aurum-custom.min.js just I have suggested you to replace.
I have even recorded a video to demonstrate this:
http://drops.laborator.co/gTwXLS
Hi Arlind
Perfect! I confirm it's now working - many thanks for that. I can see your new aurum-custom.min.js file in the wp-content/themes/aurum/assets/js directory alongside the aBeoTR.js file you sent us previously.
All the best :)
Clive
Hi Clive,
Glad to hear that. We will include this fix on our next theme update too.
Have a great day!
Will set this ticket as solved from here.