: Element’s value is not recognized in structured data According to the Microdata specification, If the <meter> element has the [value] attribute and it is an itemprop, then the itemprop
According to the Microdata specification,
If the <meter> element has the [value] attribute and it is an itemprop, then the itemprop value should be the value of that [value] attribute.
<div itemscope="" itemtype="http://schema.org/Rating">
<meta itemprop="worstRating" content="0">
<meta itemprop="bestRating" content="1">
<meter min="0" max="1" value="0.4" itemprop="ratingValue">Poor</meter>
</div>
The value of ratingValue should be 0.4, however, it is incorrectly displayed as Poor, which is the textContent of the element.
Test it in Google’s Structured Data Testing Tool. The same result is obtained with Yandex’s Structured Data Validator.
How do I get the machine to recognize the [value] attribute as the correct value?
By the way, any additional info on where I can submit bugs for these tools would be appreciated.
More posts by @Sarah324
1 Comments
Sorted by latest first Latest Oldest Best
Indeed, this seems to be a bug in their tools.
Two workarounds
Add a content attribute with the value (valid according to W3C’s current Working Draft of Microdata):
<meter min="0" max="1" value="0.4" content="0.4" itemprop="ratingValue">Poor</meter>
Move the itemprop to a meta element (valid according to all Microdata specs):
<meter min="0" max="1" value="0.4">Poor</meter>
<meta itemprop="ratingValue" content="0.4">
Terms of Use Create Support ticket Your support tickets Stock Market News! © vmapp.org2024 All Rights reserved.