<?php
$productIds = array(1,2);
$_productCollection = Mage::getModel('catalog/product')->getCollection();                              
$_productCollection->addAttributeToFilter('status', 1); //enabled
$_productCollection->addAttributeToFilter('visibility', 4); //catalog, search
$_productCollection->addAttributeToFilter('entity_id', array('in' => $productIds));
?><span id="more-6"></span>


<?php  
foreach ($_productCollection as $_product)
{
 
       $model = Mage::getModel('catalog/product');
       $product_id = $_product->getId();
       $_product = $model->load($product_id);
       //echo $_product->getPrice()."";
       //echo $_product->getName()."";
       $_image=Mage::getModel('catalog/product')->load($product_id);
       //echo Mage::helper('catalog/image')->init($_image, 'image')."";
       ?>
        <div class="feature-product">
            <div class="feature-product-price"><?php echo $_product->getPrice(); ?></div>
            <div class="feature-product-name"><?php echo $_product->getName(); ?></div>
            <div class="feature-product-image"><a href="<?php echo $_product->getProductUrl() ?>"><img src="<?php echo Mage::helper('catalog/image')->init($_image, 'image')->resize(200,200); ?>"></a></div>
        </div>
   <?php 
}                                       
?>

Categories: Magento

0 Comments

Leave a Reply

Avatar placeholder

Your email address will not be published. Required fields are marked *