开发者

Magento - Different price style on grid and product info

I'm trying to change the styles of the price on the different pages. In the product grid it's in the 'standard' look, but on the product info page I would like to show it bigger. I figured out that the price is called in view.phtml with this line:

<?php echo $this->getChildHtml('product_type_data') ?>

The product_type_data is in the file default.phtml (template/catalogue/product/view/). Here I see:

<?php echo $this->getPriceHtml($_product) ?>

The getPriceHtml() again is in the price.phtml.

The style is in the CSS:

.special开发者_Go百科-price .price { font-size:18px; color:#990000; font-weight:bold; }

Is it possible to create a separate css-rule (eg .special-price .price-large) and how to apply it only to the productview?


Look for something that is unique to product grids and use that. There is no need to change the HTML as well.

.products-grid .special-price .price { font-size:20px; }
0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜