【问题标题】:Magento 1.6.1.0, how to access a products thumbnail or base images instead of the small_imageMagento 1.6.1.0,如何访问产品缩略图或基本图像而不是 small_image
【发布时间】:2012-02-11 15:37:19
【问题描述】:

我每个产品有两张图片,一张是简单的图片,一张是拼贴类型的图片。简单的图片是small_image,拼贴图片在base和thumbnail中。

这是我用来抓取 small_image 的: helper('目录/图像')->init($_product, 'small_image'); ?>" width="250" />

我将如何获取 base_image?

谢谢

【问题讨论】:

    标签: magento


    【解决方案1】:

    该辅助方法的第二个参数是属性名称,基本图像的属性名称就是“图像”。所以应该是……

    helper('catalog/image')->init($_product, 'image'); 
    

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2019-07-07
      • 1970-01-01
      • 2014-07-26
      • 1970-01-01
      • 2012-08-13
      • 1970-01-01
      相关资源
      最近更新 更多