News:

Support the VirtueMart project and become a member

Main Menu

Cart module + back button bug

Started by marcodelpercio, March 07, 2012, 13:51:48 PM

Previous topic - Next topic

marcodelpercio

Hi

With Firefox (ver. 10.x) and Chrome (ver. 11.x) the default Virtuemart 2 cart module is being tricked showing wrong info when using browser's back button.

How to reproduce the bug:
Keep the cart module visible and add a product to the cart (whatever quantity) then clic on the little x or elsewhere on the screen to close the facebox overlay. Now you should see your product appearing in the cart module (updated via ajax), now hit the browser back button (i.e. to go back to category view) and the cart module will not display the just added product, if you refresh the page or navigate somewhere else the cart module will refresh and it'll show the correct updated information.

Suggested workaround:
In the cart module view add the following code:

jQuery(".vmCartModule").productUpdate();

on document ready to always refresh the cart to the most up-to-date situation.

I'm on Joomla 2.5.2 using Virtuemart 2.0.2 public release

RCheesley

Hi there,

I have this problem happening in 1.5.26 with 1.1.9 VM.

I might be being totally thick but could you be a bit more explicit as to how to resolve this?  I'm using mod_virtuemart_cart.

Ruth