Mobile app version of vmapp.org
Login or Join
Berryessa370

: Schema.org/Book with multiple authors using JSON-LD How do I display multiple book authors using JSON-LD? This question is similar to my original question, but decided to create a different one

@Berryessa370

Posted in: #Html #Html5 #JsonLd #Microdata #SchemaOrg

How do I display multiple book authors using JSON-LD?

This question is similar to my original question, but decided to create a different one seeing that 2 different formats are used.

Here is my post using microdata:

schema.org/Book with multiple authors

My question is similar. I have a book with multiple authors. Am I doing it correctly by displaying the author property more than once? Below is the code using JSON-LD:

<script type="application/ld+json">
{
"@context": "http://schema.org",
"@type": "WebPage",
"mainEntity": {
"@type": "Book",
"author": {
"@type": "Person",
"familyName": "van der Westhuizon",
"givenName": "Jason",
"name": "Jason van der Westhuizon"
},
"author": {
"@type": "Person",
"familyName": "du Toit",
"givenName": "Jene",
"name": "Jene du Toit"
},
"author": {
"@type": "Person",
"familyName": "September",
"givenName": "Koos",
"name": "Koos September"
},
"bookFormat": "http://schema.org/Paperback",
"datePublished": "2014-11",
"inLanguage": "en",
"isbn": "1234567890123",
"name": "My Book Name",
"numberOfPages": "381",
"publisher": {
"@type": "Organization",
"name": "My Publisher"
},
}
}
</script>


The reason why I ask is because when I go to Google's structured data tester tool then in the results it only shows one author. Why doesn't it display all 3? Is my code wrong?

10.01% popularity Vote Up Vote Down


Login to follow query

More posts by @Berryessa370

1 Comments

Sorted by latest first Latest Oldest Best

 

@Bryan171

your code contains error, thats why two authors aren't recognized. If you have more then one author, you should add them as list without entity duplication. Here the correct code:

<script type="application/ld+json">
{
"@context": "http://schema.org",
"@type": "WebPage",
"mainEntity": {
"@type": "Book",
"author": [{
"@type": "Person",
"familyName": "van der Westhuizon",
"givenName": "Jason",
"name": "Jason van der Westhuizon"
},
{
"@type": "Person",
"familyName": "du Toit",
"givenName": "Jene",
"name": "Jene du Toit"
},
{
"@type": "Person",
"familyName": "September",
"givenName": "Koos",
"name": "Koos September"
}],
"bookFormat": "http://schema.org/Paperback",
"datePublished": "2014-11",
"inLanguage": "en",
"isbn": "1234567890123",
"name": "My Book Name",
"numberOfPages": "381",
"publisher": {
"@type": "Organization",
"name": "My Publisher"
}
}
}
</script>

10% popularity Vote Up Vote Down


Back to top | Use Dark Theme