Jump to content

Problem add cart


drabe

Recommended Posts

Hi,

I have an issue with my add cart button, it doesn't work, it displays a pop-up which says the product is not available but it is. I have tried some things but none have worked..

Code of my button : 

<div class="produitpageproductlist_cart">
								
<input type="hidden" name="qty" id="quantity_wanted_{$product_id{$i[spam-filter]" value="{$minimal_quantity_{$i[spam-filter]">
<a class="ajax_add_to_cart_button" rel="ajax_id_product_{$product_id{$i[spam-filter]" href="{$base_dir}/index.php?controller=cart&add=1&&qty=6&id_product={$product_id{$i[spam-filter]&token=edd23a39176f5b38b4ba6a45d725d5f7" title="Ajouter au panier"><img src="{$base_dir}/modules/produitpageproductlist/cart.png"/></a>
</div>

I'm on Prestashop 1.6.

Url of the page ( the button is in the left collumn "Nos meilleurs ventes en Bordeaux") :

 http://www.creation-site-wordpress.fr/lvdf/index.php?id_category=11&controller=category

 

Thank you in advance :)

Link to comment
Share on other sites

You need to add  data-id-product to anchor so try with 

<div class="produitpageproductlist_cart">
								
<input type="hidden" name="qty" id="quantity_wanted_{$product_id{$i[spam-filter]" value="{$minimal_quantity_{$i[spam-filter]">
<a class="ajax_add_to_cart_button" rel="ajax_id_product_{$product_id{$i[spam-filter]" href="{$base_dir}/index.php?controller=cart&add=1&&qty=6&id_product={$product_id{$i[spam-filter]&token=edd23a39176f5b38b4ba6a45d725d5f7" data-id-product="{$product_id{$i[spam-filter]" title="Ajouter au panier"><img src="{$base_dir}/modules/produitpageproductlist/cart.png"/></a>
</div>
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...