When I use the Organization-Schema and test the result in Google's Structured Data Testing Tool, it states that an image is necessary. Can we add an ImageObject Field?

Comments

Eric Heydrich created an issue. See original summary.

eric heydrich’s picture

Status: Active » Needs review
StatusFileSize
new1.24 KB

I've added SchemaOrganizationImage.php to schema_organization submodule. I added the Image, tested it in Google Structured Data Testing tool and it works fine.

damienmckenna’s picture

Version: 8.x-1.0-rc4 » 8.x-1.x-dev
Issue tags: -Drupal 8, -Metatags, -schema.org
StatusFileSize
new1.1 KB

The patch didn't create the initial SchemaOrganizationImage.php file so the patch wouldn't work.

This recreates the file from the original SchemaArticleImage.php file.

eric heydrich’s picture

Ahh thank you.

damienmckenna’s picture

No problem.

Note: you might have needed to do "git diff HEAD" in order to see all of the changes.

agarzola’s picture

StatusFileSize
new2.19 KB

I’ve added an updated patch that adds a logo field, since that’s an acceptable alternative to image.

It also updates the previous patch to use capitalization in the label (Image instead of image) and sets the weight for both fields to 3 so that it falls underneath all text fields (it was falling between telephone and url, which was a bit jarring).

christophweber’s picture

Status: Needs review » Reviewed & tested by the community

Patch schema_metatag-2909561-4.patch from #6 works great for me, and the resulting JSON-LD validates. I'd say we have an MVP here ready to go.

On a side note: For LocalBusiness and its more granular derivatives Google recommends also outputting PriceRange, and of course we will want AggregateRating and ratingCount to achieve those vaunted stars in Rich Snippets, but that's another issue altogether discussed in https://www.drupal.org/project/schema_metatag/issues/2916438.

eric heydrich’s picture

Assigned: eric heydrich » Unassigned

  • KarenS committed 6002674 on 8.x-1.x authored by Eric Heydrich
    Issue #2909561 by Eric Heydrich, DamienMcKenna, agarzola, ChristophWeber...
karens’s picture

Status: Reviewed & tested by the community » Fixed

I switched the case of the labels back to lower case for consistency with other tags. I am using the case stipulated in Schema.org, not trying to uppercase labels. Otherwise this looks great. Thanks!

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.

nikky171091’s picture

Hi Guys

Any one create the patch for Uploaddate field in ImageOject ..

summit’s picture

Hi, made issue for D7, same problem; https://www.drupal.org/project/schema_metatag/issues/3086328. Greetings, Martijn