: Structured data. Img. Width With structured data and img width and height, Google says "number required". Does it mean that Google only accepts the numbers in pixels? https://developers.google.com/search/docs/data-types/articles
With structured data and img width and height, Google says "number required". Does it mean that Google only accepts the numbers in pixels? developers.google.com/search/docs/data-types/articles
<div itemprop="image" itemscope itemtype="https://schema.org/ImageObject">
<img src="https://google.com/thumbnail1.jpg"/>
<meta itemprop="url" content="https://google.com/thumbnail1.jpg">
<meta itemprop="width" content="800">
<meta itemprop="height" content="800">
</div>
But nowadays almost all img need to be responsive. So the img CSS is:
img {
width: 100%;
height: auto;
}
and the structured data:
<meta itemprop="width" content="100%">
<meta itemprop="height" content="auto">
In structured data, the values of the width and height, how should it be? Can I use 100% and auto?
More posts by @Gail5422790
1 Comments
Sorted by latest first Latest Oldest Best
Schema.org’s height/width properties are not for stating in which dimension the image should be displayed, but which dimension the image file has.
Knowing the image’s height/width, consumers (like Google Search) can then decide if to do something (and what to do) with the image. They will use their own CSS if they display the image.
In the case of Google Search, they want to see pixel values, e.g., for their Article rich result:
The height of the image, in pixels.
The width of the image, in pixels.
Terms of Use Create Support ticket Your support tickets Stock Market News! © vmapp.org2024 All Rights reserved.