0

How can i display certain selected products in the checkout tabs by attribute-value?. I have some Products which have individual information for freight and i would like top display them within the fright-tab in checkout. But just these products.

How can i manage this. I found this script:

                            $quote = Mage::helper('checkout')->getQuote();
                            foreach ($quote->getItemsCollection() as $item) {
                                // output details of an item.
                                echo $item->getName();

but i displays very products from the cart. I just want to display the product which have value in this right-attribute.

0

You could foreach through that list and check if the corresponding product has the attribute you are looking for.

$quote = Mage::helper('checkout')->getQuote();
foreach ($quote->getItemsCollection() as $item) {
    if ($quote->getProduct()->hasFreight()) {
        // Show this product..
    }
}

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.