- Issue created by @drupaldope
- Status changed to Postponed: needs info
5 months ago 1:40pm 8 August 2024 - 🇩🇪Germany spuky
I'd like to understand this a little more..
Google allows a last Item without a link and the current page must not be in the navigation path. So its maybe an issue in the Schema.org WebPage Submodule of Schema.org Metatag module.
The json+ld Option of Easy Breadcrumb generates the Schema markup so is there a reason to use.. Metatags module instead of Easy Breadcrumbs...
@spuky
thanks for your comment, but could you please explain more ?
the current page needs to go into the schema breadcrumbs.
how do you propose to achieve this ?- 🇩🇪Germany spuky
Unless you have a very special usecase (For most people it is making Google Search console happy) you could just use the:
Add current breadcrumb as structured data.
of easy breadcrumb which adds schema.org json+ld markup to the header of the page and only add the rest of the schema.org tags via the Metatag module.
@spuky
https://developers.google.com/search/docs/appearance/structured-data/bre...
unless I'm mistaken, the above google spec for breadcrumbs says all breadcrumbs should have a link associated ?
I want to provide google with the corresponding metadata, but also display a neat breadcrumb to the user.
- leymannx Berlin
Please paste the JSON LD from the HTML head here.
Please double check that you've read https://developers.google.com/search/docs/appearance/structured-data/bre....
- leymannx Berlin
Sorry, you posted the same link. But do you see the sample markup? The last item has no link.
<html> <head> <title>Award Winners</title> <script type="application/ld+json"> { "@context": "https://schema.org", "@type": "BreadcrumbList", "itemListElement": [{ "@type": "ListItem", "position": 1, "name": "Books", "item": "https://example.com/books" },{ "@type": "ListItem", "position": 2, "name": "Science Fiction", "item": "https://example.com/books/sciencefiction" },{ "@type": "ListItem", "position": 3, "name": "Award Winners" }] } </script> </head> <body> </body> </html>
@leymannx
how about this example from the same page ?
{ "@context": "https://schema.org", "@type": "BreadcrumbList", "itemListElement": [{ "@type": "ListItem", "position": 1, "name": "Books", "item": "https://example.com/books" },{ "@type": "ListItem", "position": 2, "name": "Authors", "item": "https://example.com/books/authors" },{ "@type": "ListItem", "position": 3, "name": "Ann Leckie", "item": "https://example.com/books/authors/annleckie" }] }
the example on schema.org also has a link:
https://schema.org/BreadcrumbList{ "@context": "https://schema.org", "@type": "BreadcrumbList", "itemListElement": [ { "@type": "ListItem", "position": 1, "item": { "@id": "https://example.com/dresses", "name": "Dresses" } }, { "@type": "ListItem", "position": 2, "item": { "@id": "https://example.com/dresses/real", "name": "Real Dresses" } } ] }
and finally, the issue with the module is the following:
"If the current page is not a link, it won't be added."
the question is not whether the current page should be a link or not, the problem is that the module won't add the current page to the breadcrumblist UNLESS it's a link.
- leymannx Berlin
Seems both are valid, with and without the last item having link.
But can you please, once again, clearly state your problem? (At best one per issue.)
How it is now, and what do you expect it instead?
I think in 🐛 Regression in Json+LD output Fixed we made the last item have no link.
- leymannx Berlin
It would also help a lot if you rephrase the title of the issue.
- 🇩🇪Germany spuky
@leymax #3458010 was about only allowing the last Item having no link since it is Possible with other Features like custom Breadcrumbs to introduce Elements that have no link to be added to the chain...
And since I am dog fooding dev on one of my customer sites am I got the waring about invalid json+ld markup pretty quickly...
Google Search Console was never complaining about an missing URL in the last Element of the Breadcrumb path...
it was complaining before i used the patch from #3340203 (which landed in 2.07)
and when using using Dev or a Patched version including (#3446802) before #3458010I am planing on doing a release this week. Since DEV is working pretty stable since 2 Weeks on 3 customer sites.
- 🇩🇪Germany spuky
it kind of depends in the original description he was talking about using the
Schema.org WebPage Submodule of Schema.org Metatag module at least i conclude that since "add to schema metatags" is not an option of EB but then It would be Schema.org WebPage that is not allowing the elements..
I guess we are still in the process of Figuring out the Problem if there is one ;-)
okay, please activate the following options and see what happens:
- Include the current page as a breadcrumb segment
- Make the current page title segment a link- 🇩🇪Germany spuky
What happens where ?
EB implementation of json+ld schema markup will produce expected results..
turning both options on will generate a last element with a item containing the url ...
turning only the first option on will generate a last element without the item ( google knows the URL it is on anyway)turning both off will have the parent as last element which is also valid since google knows the URL and the Title of the page it is on anyways...
So please define the Problem if there is one.
Are you using the EB option to add Json ld (which does not need metatags module) or are you trying to add the schema markup via Metatags module ?
the issue with the options setting I described in #17 is that while everything is correct on the metatags level, the breadcrumbs displayed on the website show the page title twice, once with a link and once without a link, such as:
home (link) > big category (link) > subcategory (link) > current page title (link) - current page title (no link)
- 🇩🇪Germany spuky
As I said with the EB implementation of the json+ld output everthing is working as expected for me...
just on Link in the breadcrub on the page...
json+ld with link to the current page...but as i Said I use Metatags for other tags... but for the breadcrumb I use the Easy breadcrub option...
If you get two elements in the breadcrumb your theme or another module might also be adding the current page.
try switching to another theme like Olivero and see if the issue persists..