ANGELO Vintage Posted March 16, 2017 Share Posted March 16, 2017 I've verified the shema.org compliance with google structured data testing tool and the Product shown in new arrival tab in the home page have wrong price value. exploring the code: <span itemprop="price" class="price product-price"> 950,00 € </span><meta itemprop="priceCurrency" content="EUR" /> The € symbol is not compliance with the schema.org: http://schema.org/price the price value must be only numeric like for example: "offers": { "@type": "Offer", "availability": "http://schema.org/InStock", "price": "55.00", "priceCurrency": "USD" } I've tried to find out where in the theme is possible to remove the €/USD symbol but i was not able to find a solution. Ty for any help Link to comment Share on other sites More sharing options...
ANGELO Vintage Posted March 16, 2017 Author Share Posted March 16, 2017 (edited) After some testing and debugging, i found a fast solution to make price compliant with google microdata testing tool and schema.org. Editing the product-list.tpl and modify the liens like: {if !$priceDisplay} {$rightPrice = {convertPrice price=$product.price|floatval[spam-filter] {else} {$rightPrice = {convertPrice price=$product.price_tax_exc|floatval[spam-filter] {/if} {$nocurrencySignPrice = {$rightPrice|regex_replace:"/[\\{$currencySign} ]/":""[spam-filter] {$finalPrice = {$nocurrencySignPrice|regex_replace:"/[\\,]/":"."[spam-filter] <meta itemprop="price" content="{$finalPrice}" /> <span class="price product-price"> {hook h="displayProductPriceBlock" product=$product type="before_price"} {if !$priceDisplay}{convertPrice price=$product.price}{else}{convertPrice price=$product.price_tax_exc}{/if} </span> Edited March 16, 2017 by ANGELO Vintage (see edit history) Link to comment Share on other sites More sharing options...
eversunpl Posted June 9, 2017 Share Posted June 9, 2017 For me working <span itemprop="price" class="price product-price" content="{$product.price}"> Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now