Hello,
I'm using wpDiscuz on a site where users will leave reviews for posted Movies. For this purpose I'm using the Comment Rating together with the hook code for Movie Aggregate Rating that you've provided here: https://wpdiscuz.com/community/f-a-q/post-rating-using-aggregate-rating-schema/
So far its working great as the ratings are being pulled by Google's Structured Data Testing Tool. The image detail is however missing from the markup which is returning an error:
I already have this image on the post as a custom field as well as the other two missing details that have a warning. I have tried adding my own markup to add these details however this ends up generating two movie markups.
So I was wondering if there was a way I could add these missing details (even if its through some code) to the schema markup wpDiscuz is generating in addition to changing the name from Average Rating to the Movie's name (title of the post) so that I end up with something of the sort:
@type
|
Movie
|
name
|
E.T
|
aggregateRating
|
|
@type
|
AggregateRating
|
bestRating
|
5
|
worstRating
|
1
|
ratingValue
|
4
|
ratingCount
|
1
|
image
|
|
dateCreated
|
2018-10-05
|
director
|
Steven Spielberg
|
Hi @hillsgrace,
The code provided in the post is just an example. For other rating properties, you'll need to customize the code and make it work the way you need.