Hi @brit77
Could you confirm you are using the latest version of Yoast SEO for WordPress v16.5?
We do know that even if you aren’t using the Yoast SEO breadcrumbs and have disabled it in the settings, it will still output the breadcrumb schema itself in the Yoast SEO schema graph.
If you want to disable the schema entirely or modify the default schema output (such as to remove the breadcrumbs), we’d like to refer you to our Schema API documentation here – https://developer.yoast.com/features/schema/api/
Thread Starter
brit77
(@brit77)
Hi @mikes41720,
Yes, can confirm I am using v16.5.
The notice is triggered only on the numbered blog pages, I assume because the script is inserted on these pages but there are no breadcrumbs. So, I can just insert the following code to prevent the script from running on these pages? (though the plugin apparently knows not to insert the script on all other pages!)
add_filter( 'wpseo_schema_graph_pieces', 'remove_breadcrumbs_from_schema', 11, 2 );
@mikes41720
The code snippet you have picked up is incomplete, you need to copy-paste the complete code as referenced here: https://developer.yoast.com/features/schema/api/#removing-graph-pieces.
add_filter( 'wpseo_schema_graph_pieces', 'remove_breadcrumbs_from_schema', 11, 2 );
breadcrumbs_from_schema( $pieces, $context ) {
return \array_filter( $pieces, function( $piece ) {
return ! $piece instanceof \Yoast\WP\SEO\Generators\Schema\Breadcrumb;
} );
}
Another workaround to rule out the cause of the breadcrumb error. We recommend you perform a conflict check.
Often, we see problems occur in combination with another plugin or theme. The fastest way to rule out any conflict, is to deactivate all non-Yoast plugins and switch to a standard theme like Twenty Twenty.
Please test this on your development or staging site, if you have one. If not, we recommend using the Health Check & Troubleshooting plugin. This plugin has a troubleshooting mode, which does not affect normal visitors to your site.
If you’re unfamiliar with checking for conflicts, we’d like to point you to a step-by-step guide that will walk you through the process: How to check for plugin conflicts
We hope this helps you to figure out the culprit plugin or theme that was causing the breadcrumb error.
We are going ahead and marking this issue as resolved due to inactivity. If you require any further assistance please create a new issue.
Thread Starter
brit77
(@brit77)
This issue appears to be resolved as of Yoast version 1.6. Thanks!