Skip to main content

Microdata error on product module

More
10 years 5 months ago #239270 by mojweb
-- HikaShop version -- : 2.6.2
-- Joomla version -- : 3.5.1
-- PHP version -- : 5.4
-- Browser(s) name and version -- : Crome

In case i have ralated product (content module) in product layout, Google microdata for price give me error.

If there is no related products, all is ok. I think that itemprop price should not be in module on product detail layout.
The following user(s) said Thank You: vanway

Please Log in or Create an account to join the conversation.

More
10 years 5 months ago #239276 by nicolas
Hi,

Thank you for your feedback.
Change the line:
Code:
echo '<span class="'.implode(' ',$classes).'" itemprop="price" content="'. $price->price_value_with_tax .'">';
to:
Code:
$attributes = ''; if(!empty($this->element->product_id)){ $round = $this->currencyHelper->getRounding($price->price_currency_id, true); $attributes = ' itemprop="price" content="'. $this->currencyHelper->round($price->price_value_with_tax, $round) .'"'; } echo '<span class="'.implode(' ',$classes).'"'.$attributes.'>';
in the file "listing_price" of the view "product" via the menu Display>Views and that will fix the problem.
The following user(s) said Thank You: vanway

Please Log in or Create an account to join the conversation.

More
10 years 5 months ago #239323 by mojweb
Problem solved. Thank you.

Please Log in or Create an account to join the conversation.

Time to create page: 0.170 seconds
Powered by Kunena Forum