- From: Tim Strehle <tim@strehle.de>
- Date: Thu, 2 Jun 2016 08:52:28 +0200
- To: Jarno van Driel <jarnovandriel@gmail.com>
- Cc: "schema.org Mailing List" <public-schemaorg@w3.org>
- Message-Id: <C6174EAF-4DC3-49CE-940C-1912618577C9@strehle.de>
Thanks Jarno, I think I’ll go with that one: SearchAction -> result -> ItemList -> itemListElement -> ListItem -> Thing I’ll add some non-schema properties for offset/current page and consider the problem solved :) I have updated my blog post with a new example: https://www.strehle.de/tim/weblog/archives/2016/05/30/1593 Regards, Tim > Am 31.05.2016 um 16:38 schrieb Jarno van Driel <jarnovandriel@gmail.com>: > > "I don’t think I fully understand why you went with a top-level ItemList" > > I guess that's just a habit. I normally markup web pages and on things like product listing pages it's the schema.org/ItemList <http://schema.org/ItemList> that's the main entity of the page. Something that wasn't possible to express until some months ago because there wasn't a 'mainEntityOfPage' property. Meaning the only way one could make it clear to search engines which entity they should consider being the 'main entity' was to model the graph so that the 'main entity' also was the top level entity. > > Now that 'mainEntity' and 'mainEntityOfPage' exist it doesn't really matter which entity is the top level entity, so the markup could have been expressed in a different order as well, eg: > > <script type="application/ld+json"> > { > "@context":"http://schema.org <http://schema.org/>", > "@id":"#MainEntity", > "@type":"SearchAction", > "actionStatus":"CompletedActionStatus", > "query":"john doe", > "result": > { > "@type":"ItemList", > "numberOfItems":35, > "itemListOrder":"ItemListOrderDescending", > "mainEntityOfPage": > { > "@type":"SearchResultsPage", > "url":"http://example.com/search?page=2 <http://example.com/search?page=2>", > "potentialAction": > [ > { > "@type":"SearchAction", > "name":"Did you mean 'jane doe'?", > "target": > { > "@type":"EntryPoint", > "urlTemplate":"http://example.com/?q=jane+doe <http://example.com/?q=jane+doe>" > } > }, > { > "@type":"SearchAction", > "name":"See also: 'dole'", > "target": > { > "@type":"EntryPoint", > "urlTemplate":"http://example.com/?q=dole <http://example.com/?q=dole>" > } > } > ] > }, > "itemListElement": > [ > { > "@type":"ListItem", > "@id":"#FirstSearchResult", > "previousItem":"http://example.com/search?page=1#LastSearchResult <http://example.com/search?page=1#LastSearchResult>", > "position":1, > "item": > { > "@type":"ImageObject", > "name":"Photo of Jane Doe" > } > }, > { > "@type":"ListItem", > "position":2, > "item": > { > "@type":"ImageObject", > "name":"Photo of John Doe" > } > }, > { > "@type":"ListItem", > "@id":"#LastSearchResult", > "nextItem":"http://example.com/search?page=3#FirstSearchResult <http://example.com/search?page=3#FirstSearchResult>", > "position":3, > "item": > { > "@type":"ImageObject", > "name":"Photo of John Doe" > } > } > ] > } > } > </script>
Received on Thursday, 2 June 2016 06:52:56 UTC