问题
I've added Schema.org on my blog list with JSON-LD:
{
"@context": "http://schema.org",
"@type": "BlogPosting",
"headline": "Fixer la navigation Off-Canvas sur Foundation",
"image": "https://stephane-richin.s3-eu-central-1.amazonaws.com/S/foundation-website.jpg",
"author": "Stéphane Richin",
"datePublished": "2015-02-03",
"dateModified": "2015-02-03",
"publisher": {
"@type": "Organization",
"name": "Stéphane Richin",
"url": "http://stephane-richin.fr",
"logo" : "http://stephane-richin.fr/images/logo/logo-stephane-richin.svg"
},
"mainEntityOfPage": "True"
}
But, I've 2 warnings on image
and logo
:
image.itemtype has wrong value
logo.itemtype has wrong value
Do you have any idea why image and logo have wrong values?
回答1:
Looks like in order to pass the Structured Data Testing Tool you need to use ImageObject
as a required property of image
and publisher.logo
.
From their documentation:
image - ImageObject, required
Your final code will look like:
{
"@context":"http://schema.org",
"@type":"BlogPosting",
"headline":"Fixer la navigation Off-Canvas sur Foundation",
"image": {
"@type": "ImageObject",
"url": "https://google.com/thumbnail1.jpg",
"height": 800,
"width": 800
},
"author": {
"@type": "Person",
"name": "Stéphane Richin"
},
"datePublished":"2015-02-03",
"dateModified":"2015-02-03",
"publisher": {
"@type":"Organization",
"name":"Stéphane Richin",
"url":"http://stephane-richin.fr",
"logo": {
"@type": "ImageObject",
"url": "https://google.com/logo.jpg",
"width": 600,
"height": 60
}
},
"mainEntityOfPage": "True"
}
I also amended it to recognise the author as Person schema.
来源:https://stackoverflow.com/questions/40155971/warning-that-image-and-logo-have-wrong-values