【发布时间】:2016-03-16 11:09:34
【问题描述】:
我想显示支持 MAP 的产品的零售价。我尝试编辑 view.phtml 文件并这样做:
<div class="pro-info">
<?php if($_product->getData('msrp_enabled') == 1): ?>
<div class="price-box">
<p class="regular-price">
<span class="price-label">Retail Price:</span>
<span id="product-price-<?php echo $_product->getId(); ?>" class="price">
<span class="price">
<?php echo $this->helper('core')->formatPrice($_product->getPrice(), false) ?>
</span>
</span>
</p>
</div>
<?php endif;?>
这显示了零售价,但问题是;对于某些产品,它会显示特价。首先,当网站加载时,它会显示零售价,然后突然改变并显示特价。 我尝试通过 Ctrl+U 查看页面的来源,它在零售价中显示原始价格,但在前端页面中显示特价。
我还注意到,对于某些产品 Product.OptionsPrice([]) 包含值,而对于某些产品则没有。无论哪个产品在Product.OptionsPrice([]) 中具有值,都有问题。
谁能帮忙??
【问题讨论】:
标签: magento magento-1.9