开发者

Fetching Magento thumbnail

开发者 https://www.devze.com 2023-03-13 20:32 出处:网络
We have a quote page with the following code for fetching item information but we can\'t get the product image to show.

We have a quote page with the following code for fetching item information but we can't get the product image to show.

<tr>
  <td rowspan="<?php echo $mergedCells; ?>" class="cart-image"><img src="<?php echo $item->getProductThumbnail(); ?>" width="75" height="75"/></td>
  <td><?php echo $item->getName(); ?> <?php echo $item->getProductOptions(); ?><br />
    <?php echo $this->__('SKU:') ?> <?php echo $item->getSku(); ?></td>
  <td class="ItemQty"><?php echo $this->getItemQty($item); ?></td>
</tr>

Have tried a couple of different solutions but still getting the same result, would be great if anyone has a so开发者_StackOverflow社区lution or an idea we can try.


<?php $item = $this->getItem() ?>

Try adding this before your getProductThumbnail() call.

You may also want to try:

<img src="<?php echo $this->getProductThumbnail()->resize(50); ?>" alt="<?php echo $this->htmlEscape($this->getProductName()) ?>" /></a>

0

精彩评论

暂无评论...
验证码 换一张
取 消