How to Show Magento Particular Categorie Image in Magento?

<?php
$cat_id = 8; // set desired category id
$category = Mage::getModel('catalog/category')->load($cat_id);
$products = $category->getProductCollection()->
addCategoryFilter($category)->addAttributeToSelect('*');
?>
<?php foreach ( $products as $_product ): ?>
<a href="<?php echo $_product->getProductUrl() ?>">
<img src="<?php echo $this->helper('catalog/image')->
init($_product, 'small_image')->resize(135, 135); ?>"
width="135" height="135" title="<?php echo $_product->getName() ?>"
alt="<?php echo $_product->getName() ?>" /></a>
<?php endforeach; ?>

How to Reduce Magento Resize Product Image Size?

<?php
$_helper = $this->helper('catalog/output');
$productId = $this->getProduct_id();
$_product = Mage::getModel('catalog/product')->load($productId);  //load the product
$_img = '<a id="a_image" href="'.$_product->getProductUrl().'" title="">
<img id="image".src="'.$this->helper('catalog/image')->
init($_product, 'image')->constrainOnly(TRUE)->
keepAspectRatio(TRUE)->resize(176,251).'" alt="'.$this->
htmlEscape($this->getImageLabel()).'" title="'.
$this->htmlEscape($this->getImageLabel()).'"/></a>';
echo $_helper->productAttribute($_product, $_img, 'image');
?>
© 2020 Spirituality