W3C home > Mailing lists > Public > public-schemaorg@w3.org > March 2016

Question on using the schema.org encoded in JSON-LD for a website

From: info <info@dafweb.it>
Date: Wed, 16 Mar 2016 19:28:57 +0100
Message-Id: <O45A09$4FBFF187355033C2F70EB6017E04D86D@dafweb.it>
To: public-schemaorg@w3.org
Dear schema.org team,
I'm writing here because I cannot find a forum or other resources to post my question.
The question is also a kind of comment to highlight the fact that the examples available on the schema.org website as well as the "get started" [1] section is not complete enough.
Let me explain better. I'm trying to encode in JSON-LD the semantic information related to a website using schema.org.
The web site is very basic: it contains the home page, a gallery page with a list of images and the image detail.

Reading the different examples from the schema.org website, and having a look also at the "get started" [1] section, it is not so easy to understand which information have to be provided in each page.

To clarify the question, I can provide a snippet of code [2] that I'm trying to create, by deducing the needed information after reading the schema.org documentation.

Below the list of specific questions:
- Does the information provided in the home page need to be repeated in all of the other pages? In this case, how the additional information shall be encoded (how to state that the page is a ImageGallery or ImageObject)?
- How to match (in the image detail page) the image with a URI to semantically link the thing in the image to a real world thing (using for example a dbpedia.org/resource/_URI_)?

An additional comment, is to try to extend the "get started" [1] section to the use of JSON-LD, which could be a better option to represent semantic data (without mixing it with the HTML presentation).

Thank you in advance.

[1] http://schema.org/docs/gs.html

[2] EXAMPLE:
-------------
HOME PAGE

{ "@context":"http://schema.org",

   "@type":"WebSite",
   "name":"Site name abc",
   "alternateName":"ABC",
   "description":"description",
   "keywords":"keywords",
   "inLanguage":"en",
   "url":"http://www.thewebsiteurl.com",
   "potentialAction":{
     "@type":"SearchAction",
     "target":"http://www.thewebsiteurl.com/find/{search_term_string}",
     "query-input":"required name=search_term_string"
   }
}

GALLERY PAGE

{  "@context":"http://schema.org",
   "@type":"ImageGallery",
   "description":"description",
   "keywords":"keywords",
   "associatedMedia":[
   {
	   "@type":"ImageObject",
	   "contentUrl": "http://...../image1URL.jpg",
   },
   {
           "@type":"ImageObject",
	   "contentUrl": "http://...../image2URL.jpg",    
   },
   .....
   ]
}

IMAGE DETAIL PAGE

{
  "@context": "http://schema.org",
  "@type": "ImageObject",
  "author":{
	"@type": "Person",
	"name":"abc"
  },
  "contentLocation":{ 
	  "@type": "Place",
	  "geo": {
		"@type": "GeoCoordinates",
		"latitude": "[latitude]",
		"longitude": "[longitude]"
	  },
	  "name": "Place name"
  },
  "copyrightHolder":{
	  "@type": "Organization",
	  "email": "info@example.mail",
	  "url" : "http://www.thewebsiteurl.com"
  },
  "contentUrl": "http://...../image1URL.jpg",
  "datePublished": "[date]",
  "description": "description",
  "keywords":"keywords",
  "name": "Image name",
  "exifData":[
  {
	"@type": "PropertyValue",
	"name": "Exposure Time",
	"value": "1/10 sec."
  },
  .....
  ]   
}
-------------
Received on Thursday, 17 March 2016 09:42:57 UTC

This archive was generated by hypermail 2.4.0 : Friday, 17 January 2020 17:12:24 UTC