Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

WooCommerce Product Schema appears under Yoast SEO Breadcrumbs in Google Structured Data Tool #10314

Closed
Pcosta88 opened this issue Jul 10, 2018 · 21 comments

Comments

@Pcosta88
Copy link
Contributor

@Pcosta88 Pcosta88 commented Jul 10, 2018

  • I've read and understood the contribution guidelines.
  • I've searched for any related issues and avoided creating a duplicate issue.

Please give us a description of what happened.

WooCommerce Product Schema appears under Yoast SEO Breadcrumbs.

Please describe what you expected to happen and why.

Only one Breadcrumb data would appear and WooCommerce Product Schema would appear on own line in Google Structured Data tool NOT combined with the Yoast SEO Breadcrumb schema.

How can we reproduce this behavior?

1.Add Yoast SEO Breadcrumbs to your site

2.Enable them in the SEO-Search Appearance-Breadcrumbs section. See that they appear

screen_shot_2018-07-10_at_1_09_14_pm

3.Create a WooCommerce Product

4.Run it through the structured data tool

5. See two Breadcrumb schema are identified.

screen shot 2018-07-10 at 1 02 51 pm

6. The top set of Breadcrumb schema is from Yoast. The Yoast SEO Breadcrumb schema is highlighted in the source code

screen_shot_2018-07-10_at_1_04_55_pm

7. The bottom Breadcrumb schema is from WooCommerce. The WooCommerce breadcrumb schema is highlighted in the source code

3

8.See that the WooCommerce Product Schema is not highlighted under the WooCommerce Breadcrumbs

5

9.However, see that the WooCommerce Product Schema IS highlighted under the Yoast SEO Breadcrumbs

7

10.Disable Yoast SEO Premium

11.See WooCommerce Breadcrumbs and WooCommerce Product appear on their own individual lines

screen shot 2018-07-10 at 1 25 13 pm

12.See WooCommerce Breadcrumbs highlight breadcrumb schema

1

13.See WooCommerce Product Highlight product schema

3

Screenshots

If applicable, add screenshots to help explain your problem.

Additional context

Add any other context about the problem here.

Technical info

  • WordPress version: 4.9.7
  • Yoast SEO version: 7.8
  • Relevant plugins in case of a bug: 3.4.3
  • Tested with theme: StoreFront (with Yoast SEO Breadcrumbs included in it)

NOTE:
Does not matter if WooCommerce SEO is enabled and the Yoast SEO WooCommerce breacrumbs are enabled. Two Breadcrumb schemas are outputted in the tool

i. Yoast SEO WooCommerce breacrumbs are enabled

screen shot 2018-07-10 at 1 19 48 pm

ii.Two Breadcrumbs

screen shot 2018-07-10 at 1 21 25 pm

@yoastbot yoastbot added the support label Jul 10, 2018
@Pcosta88

This comment has been minimized.

Copy link
Contributor Author

@Pcosta88 Pcosta88 commented Jul 10, 2018

Please inform the customer of conversation # 402420 when this conversation has been closed.

@Pcosta88 Pcosta88 changed the title Yoast SEO Breadcrumbs output two Breadcrumb schemas and prevent WooCommerce Product Schema from appearing on own line in Google Structured Data tool WooCommerce Product Schema appears under Yoast SEO Breadcrumbs Jul 10, 2018
@Pcosta88 Pcosta88 changed the title WooCommerce Product Schema appears under Yoast SEO Breadcrumbs WooCommerce Product Schema appears under Yoast SEO Breadcrumbs in Google Structured Data Tool Jul 10, 2018
@rmarcano

This comment has been minimized.

Copy link

@rmarcano rmarcano commented Jul 11, 2018

Possibly related:#10342

@Pcosta88

This comment has been minimized.

Copy link
Contributor Author

@Pcosta88 Pcosta88 commented Jul 13, 2018

Downgrading to v6.3.1 appears to resolve the issue.

screen_shot_2018-07-13_at_10_57_13_am

@jsmusiker

This comment has been minimized.

Copy link

@jsmusiker jsmusiker commented Oct 3, 2018

Why are there no Yoast employees addressing this? This is a extremely serious issue for eCommerce Sites. I can’t believe this is being ignored.

@rmarcano

This comment has been minimized.

Copy link

@rmarcano rmarcano commented Oct 5, 2018

Please inform the customer of conversation # 430026 when this conversation has been closed.

@laurasacco

This comment has been minimized.

Copy link

@laurasacco laurasacco commented Oct 18, 2018

Please, inform the customer of conversation #435316 when this conversation has been closed.

@rmarcano

This comment has been minimized.

Copy link

@rmarcano rmarcano commented Oct 18, 2018

Please inform the customer of conversation # 435239 when this conversation has been closed.

@benvaassen

This comment has been minimized.

Copy link
Member

@benvaassen benvaassen commented Oct 19, 2018

This issue is causing users to lose their product snippets on search results.

@mariusghitulescu

This comment has been minimized.

Copy link

@mariusghitulescu mariusghitulescu commented Oct 19, 2018

Please inform the customer of conversation # 435756 when this conversation has been closed.

@CarolineGeven CarolineGeven added the SEO label Oct 23, 2018
@jono-alderson

This comment has been minimized.

Copy link

@jono-alderson jono-alderson commented Oct 23, 2018

I'm aware of this issue, and working on a solution. I'm specifying a large update to the way we output schema, which should resolve this. Watch this space.

@Pcosta88

This comment has been minimized.

Copy link
Contributor Author

@Pcosta88 Pcosta88 commented Nov 8, 2018

Please inform the customer of conversation # 442217 when this conversation has been closed.

@jono-alderson

This comment has been minimized.

Copy link

@jono-alderson jono-alderson commented Nov 13, 2018

In the short-term, we should append the #product to the end of the product @id parameter.

@JeremieBALDY

This comment has been minimized.

Copy link

@JeremieBALDY JeremieBALDY commented Nov 13, 2018

I have the same issue with schema generated by Site Reviews plugin which appears inside the BreadcrumbList instead of Product

@pryley

This comment has been minimized.

Copy link

@pryley pryley commented Nov 14, 2018

I have the same issue with schema generated by Site Reviews plugin which appears inside the BreadcrumbList instead of Product

Please see: https://wordpress.org/support/topic/schema-appears-under-breadcrumblist-in-google-structured-data-tool-2/#post-10880708

@hagsonz

This comment has been minimized.

Copy link

@hagsonz hagsonz commented Dec 21, 2018

any idea when it will be fixed, or some workaround at least?

@MAJA1970

This comment has been minimized.

Copy link

@MAJA1970 MAJA1970 commented Dec 25, 2018

Workaround
I'am using a workaround since the problem stil exists for months now, I wrote it a few years ago. It is not the nicest piece of code but is working for me.

Download:
json-ld-woocommerce.txt
You have to change the organization name, it is hard coded. Change it to your own organization name and for the brand the same thing or make comments of it (Lines 126 and 131).

Rename the file to json-ld-woocommerce.php .

Copy the file to your theme or better child theme folder.

Call the code in your header.php of your theme by including it as shown here:

include in the header

To make it easy download this file and copy paste this in your header as shown above.

include-JSON.txt

Check in Google:
https://search.google.com/structured-data/testing-tool#
Put in a link to your product page and you will see the product microdata.

I'm not giving support, use it at your own risk.

Merry Christmas and happy new year 2019

@GTO-1

This comment has been minimized.

Copy link

@GTO-1 GTO-1 commented Jan 6, 2019

I am a Premium YOAST user since years and I'm shocked how long this bug is present and does harm Google search results for so many of us. PLEASE YOAST.....

@jono-alderson

This comment has been minimized.

Copy link

@jono-alderson jono-alderson commented Jan 14, 2019

Lots of moving parts here, so consolidating for simplicity.

  • In JSON-LD markup, any entity can have an ID property (an arbitrary string). That ID uniquely identifies that entity, in the context of the page it's on.
  • If multiple entities on a page share an ID, then search engines / etc may confuse and conflate those entities. In this case, the product and the breadcrumbs share the same ID, and Google is awkwardly trying to merge them.
  • There's a special case with breadcrumbs, however, where the IDs must be the URL of the page. So, no other entity on a page should ever use the URL as its ID.
  • So, the Product needs a different, unique ID.
  • We should make in WooCommerce's code.
  • For the sake of neatness, we recommend that an ID be structured as an 'extension' of the page the entity is on. E.g., in this case, the ID of the product could/should be https://www.example.com/page/#product, where the URL is the page in question.

Making this change will remove the ID collision, and resolve the conflicts. Nothing else should change/break.

A slight nuance

  • If WooCommerce is referencing the current ID anywhere (e.g., an Organization node may have a 'makesOffer' property which references the product ID), then the referenced IDs will also need to be updated to the new format.
  • I don't think that this is currently the case anywhere, but we should check.
@jono-alderson

This comment has been minimized.

Copy link

@jono-alderson jono-alderson commented Jan 14, 2019

Opened over at WooCommerce: woocommerce/woocommerce#22440

@moorscode

This comment has been minimized.

Copy link
Member

@moorscode moorscode commented Jan 17, 2019

The main problem in this issue has been resolved by the fix in Yoast SEO: WooCommerce (Yoast/wpseo-woocommerce#294)

This will disable the WooCommerce breadcrumbs when the option is selected in the plugin.

To be able to provide the most optimal schema.org implementation for Products, the WooCommerce JSON+LD output needs to change, to make sure the identifier for a product is not the URL it is on.

This is being discussed in the above-mentioned issue.

If you do not own Yoast SEO: WooCommerce, we recommend to disable the Breadcrumbs in WooCommerce and use the ones output by Yoast SEO.

Closing this in favor of: #12053

Support: Please determine if the problem for the customers that have been added to this issue has been fixed or if they need to be notified when closing #12053

@moorscode

This comment has been minimized.

Copy link
Member

@moorscode moorscode commented Feb 27, 2019

The above-mentioned fix in WooCommerce has been applied and released in 3.5.5 - see woocommerce/woocommerce#22554

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
You can’t perform that action at this time.