- <?php
- // this will fix the "add to cart" bug.
- // we need to refetch the products to get our custom attribs
- $products= Mage::getModel('catalog/product')->getCollection()
- ->addAttributeToSelect('rbanh_type')
- ->addAttributeToSelect('rbanh_price')
- ->addAttributeToSelect('rbanh_color')
- ;
- $product2 = $products->getItemById($product_id);
- $rbanhtype = $product2->getRbanh_type();
- $rbanhprice = $product2->getRbanh_price();
- $rbanhcolor = $product2->getRbanh_color();
- ?>
本文介绍了一种解决电子商务平台中“加入购物车”功能出现的问题的方法。通过重新获取商品集合并选择自定义属性如类型、价格和颜色等,确保了购物车功能的正确实现。
4159

被折叠的 条评论
为什么被折叠?



