rafraf Posted June 6, 2008 Posted June 6, 2008 Is there a way to create a Special Buy Now Button (It could be for a banner usage) in order to directly add a product to the cart with pre-selected attributes?
rafraf Posted June 12, 2008 Author Posted June 12, 2008 Solution: The following script will add to shopping cart product_id=96 with an attribute pre-selected. In order to test it ,change the values for product attributes and product id to an existing ones. <form name="cart_add" action='<? $link_carrito= "product_info.php?action=add_product&products_id=96"; echo tep_href_link($link_carrito,$osCsid);?>' method="POST"> <input type="hidden" name="id[36]" value="69"> <input type="hidden" name="products_id" value="96"> <a href="java script:document.cart_add.submit();" target="_self" >Add to cart</a> </form>
Recommended Posts
Archived
This topic is now archived and is closed to further replies.