Reputation: 3
actually i just want to retrieve product short description on checkout success page
As other item show by this code
For example name :
<?php foreach ($order_details->getAllItems() as $item) { } ?>
<?php $product_id = $item->getData('product_id'); ?>
<?php echo $item->getName() ?>
Also i need to show gift wrap amount, currently just found the shipping as
<?php echo Mage::helper("core")->currency($order_details->shipping_amount) ?>
Any suggestion will be appreciated, thanks
Upvotes: 0
Views: 1118
Reputation: 1720
<?php foreach ($order_details->getAllItems() as $item) {
$product_id = $item->getProductId(); //what is this $item->getData('product_id');
$product = Mage::getModel(catalog/product)->load($product_id);
print_r($product->getShortDescription()); } ?>
Better Solution as you should not load Model every time.
<?php $catModel = Mage::getModel(catalog/product);
foreach ($order_details->getAllItems() as $item) {
$product_id = $item->getProductId(); //what is this $item->getData('product_id');
$product = $catModel->load($product_id);
print_r($product->getShortDescription()); } ?>
Upvotes: 1