isBundle() in Magento?
-
10-10-2019 - |
문제
How do you tell if a product page is set up as a bundle in Magento 1.4? I can't find a way to do it.
해결책
this code should work in your product page (catalog/product/view.phtml):
$product = $this->getProduct();
if($product->getTypeId() === 'bundle'){
// Something…
}
다른 팁
if ($_product->getTypeId() == Mage_Catalog_Model_Product_Type::TYPE_BUNDLE) {
echo 'Bundled';
}
제휴하지 않습니다 StackOverflow