[英]PrestaShop - Create an "add to cart' button for a product on checkout
Is there a way to create an "add to cart" button for a specific product of my catalog, in the checkout process ?有没有办法在结帐过程中为我目录中的特定产品创建“添加到购物车”按钮? For example on the shipping or payment page.
例如在运输或付款页面上。
Thank you.谢谢你。
In PS 1.6 you can achieve it with a simple link like this:在 PS 1.6 中,你可以通过一个简单的链接来实现它:
http://your-shop.com/cart?add=1&id_product=1&ipa=1&token=ea77f7d7169d5044638643fe4fcd2c99
Where...在哪里...
id_product
is the product id you want to add id_product
是您要添加的产品 IDipa
is the attribute id of the product ipa
是产品的属性idtoken
is the static token token
是静态令牌Inside a smarty file you can generate a link with this code:在 smarty 文件中,您可以使用以下代码生成链接:
{$link->getPageLink('cart', true, NULL, 'add=1&id_product=1&ipa=1&token='|cat:$static_token, false)|escape:'html':'UTF-8'}
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.