Jump to content

Products not animated to card when added.


Recommended Posts

Hi.

 

Got an annoying problem with my grid view in 1.5.2

Everything is working except the animation when adding a product to the card.

 

Here are 2 links, for same products, one normal view, one grid view.

 

Grid View!

List View!

 

my ajax-cart.js is standard, though i did modify it earlier, and got it to work, but had to redo a lot of layout problems, hence it's not working anymore.

 

I use the exact same link as in default theme.

 

Got any ideas?

Link to comment
Share on other sites

I comes down to line 208 i ajax-cart.js

var $element = $(callerElement).parent().parent().find('a.product_image img,a.product_img_link img');

I tried earlier when it was working, before i had to redo a layout error to do something like

if($(callerElement).parent().parent().find('a.product_image img,a.product_img_link img') {
var $element = $(callerElement).parent().parent().find('a.product_image img,a.product_img_link img');
} else {
var $element = $(callerElement).parent().parent().find('div.product_image,a.product_img_link img');
}

 

something like that.. but cant remember what i changed it to. :S

Link to comment
Share on other sites

try to add to: var $element = $(callerElement).parent().parent().find('a.product_image img,a.product_img_link img');

div.center_block_grid img

 

something like this:

var $element = $(callerElement).parent().parent().find('a.product_image img,a.product_img_link img,div.center_block_grid img');

 

and see if it works.

 

if not keep playing with it, your image in grid view is located under different tag than in list view.

Link to comment
Share on other sites

  • 2 weeks later...
  • 2 weeks later...
  • 2 months later...

I don't know if you ever found a solution to this.

 

I have the same problem.

 

I ran a test, and got this error: "callerElement is not defined". Which for me must be the problem, as it requires callerElement in order to know which img to find...

 

So anyone know where the callerElement should get set? Why mine is not getting set? And how I can get it set?

 

Thanks, Josh.

Link to comment
Share on other sites

×
×
  • Create New...