Mobile app version of vmapp.org
Login or Join
Lee4591628

: BlogPosting Publisher Logo 'logo.itemtype has an invalid value' on Google Structured Data Testing Tool The following runs through the Google Structured Data Testing Tool as expected: <div>

@Lee4591628

Posted in: #GoogleRichSnippetsTool #Microdata #SchemaOrg

The following runs through the Google Structured Data Testing Tool as expected:

<div>
<div itemprop="publisher" itemscope id="organization-example" itemtype="https://schema.org/Organization">
<a itemprop="url" href="https://example.com">
<img itemprop="image logo" src="https://example.com/images/logo.png" alt="LOGO">
<span itemprop="name">EXAMPLE</span>
<span itemprop="description">This is an EXAMPLE</span>
</a>
</div>
</div>

<div itemscope itemtype="https://schema.org/WebPage" itemref="organization-example">
</div>


But when I try using a BlogPosting it breaks the logo property:

<div>
<div itemprop="publisher" itemscope id="organization-example" itemtype="https://schema.org/Organization">
<a itemprop="url" href="https://example.com">
<img itemprop="image logo" src="https://example.com/images/logo.png" alt="LOGO">
<span itemprop="name">EXAMPLE</span>
<span itemprop="description">This is an EXAMPLE</span>
</a>
</div>
</div>

<article
itemscope
itemtype="https://schema.org/BlogPosting"
itemref="organization-example"
>
</article>


With the error:


example.com/images/logo.png (The attribute logo.itemtype has an invalid value.)


Can anyone explain why? And what steps I could take to fix it?

10.02% popularity Vote Up Vote Down


Login to follow query

More posts by @Lee4591628

2 Comments

Sorted by latest first Latest Oldest Best

 

@Gloria169

A brilliant and helpful answer by @Arth above.

To complement the answer above (not compete with it), here is the same Structured Data using the same schema.org vocabulary, but this time in JSON-LD:

"publisher": {
"@type": "Organization",
"name": "myOrganization",
"logo": {
"@type": "ImageObject",
"name": "myOrganizationLogo",
"width": "60",
"height": "600",
"url": "http://my-organization.org/my-logo.png"
}
}


N.B. According to developers.google.com/search/docs/data-types/articles


The logo should be a rectangle, not a square.
The logo should fit in a 60x600px rectangle., and either be exactly 60px high (preferred), or exactly 600px wide. (For example,
450x45px would not be acceptable, even though it fits in the
600x60px rectangle.)

10% popularity Vote Up Vote Down


 

@Dunderdale272

Turns out, because BlogPosting is one of the types supported by Google as a possible Rich Snippet, they apply more validation:

Google Search Documentation Guidelines for Articles

This requires an Article's Publisher's logo to be of type ImageObject and have a width and height in pixels. BlogPosting is a subtype of Article.

This updated snippet validates through the Google Structured Data Testing Tool:

<div id='web-page-example' itemprop="mainEntityOfPage" itemscope itemtype="https://schema.org/WebPage" itemref="headline-example">
<div>
<div itemprop="publisher" itemscope id="organization-example" itemtype="https://schema.org/Organization">
<a itemprop="url" href="https://example.com">
<span itemprop="logo" itemscope itemtype="https://schema.org/ImageObject">
<img itemprop="url" src="https://example.com/images/logo.png" alt="LOGO">
<meta itemprop="width" content="600">
<meta itemprop="height" content="60">
</span>
<span itemprop="name">EXAMPLE</span>
<span itemprop="description">This is an EXAMPLE</span>
</a>
</div>
</div>
<div
id="blog-posting-example"
itemprop="mainEntity"
itemscope
itemtype="https://schema.org/BlogPosting"
itemref="organization-example web-page-example"
>
<span itemprop="author" itemscope itemtype="https://schema.org/Person">
<span itemprop="name">Example Author</span>
</span>
<time itemprop="datePublished" datetime="2016-05-09T11:40:04+02:00">9th May 2016</time>
<time itemprop="dateModified" datetime="2016-05-09T11:40:04+02:00">9th May 2016</time>
<h1 id="headline-example" itemprop="name headline">Example Headline</h1>
<span itemprop="image" itemscope itemtype="https://schema.org/ImageObject">
<img itemprop="url" src="https://example.com/images/blog.png" alt="LOGO">
<meta itemprop="width" content="800">
<meta itemprop="height" content="400">
</span>
</div>
</div>

10% popularity Vote Up Vote Down


Back to top | Use Dark Theme