J'ai le code HTML suivant qui contient le schéma Product
ainsi que le schéma Review
, mais pour une raison quelconque, mon Produit
& Review sont séparés sur l'outil de test des données structurées avec l'avertissement suivant sur mon schéma Product
:
Le champ de révision est recommandé. Veuillez fournir une valeur si disponible. »
Est-ce normal?
<main class="container" itemscope="" itemtype="http://schema.org/Product"> <meta itemprop="brand" content="Ticketstoday"> <div class="section position-relative"> <div class="row"> <div class="col s12 l8"> <div class="card-panel white description"> <h1 itemprop="name"></h1> <h6 class="grey-text text-darken-1"></h6> <span itemprop="description"> </span> </div> </div> </div> <div class="row"> <div class="col s12 l8"> <div class="card-panel white description"> <h2>Reviews</h2> <div itemprop="aggregateRating" itemscope="" itemtype="https://schema.org/AggregateRating"> <h6 class="grey-text text-darken-1"> Rated <span itemprop="ratingValue">4.3</span> out of <span itemprop="bestRating">5</span> (<span itemprop="ratingCount">55</span> Reviews) </h6> </div> <ul class="collection reviews"> <li class="collection-item avatar" itemscope="" itemtype="http://schema.org/Review"> <meta itemprop="itemReviewed" itemscope="" itemtype="http://schema.org/Thing"> <meta itemprop="url" content="http://ticketstoday.local/play/all-about-eve"> <span itemprop="reviewRating" itemscope="" itemtype="http://schema.org/Rating"> <meta itemprop="ratingValue" content="5"> </span> <span itemprop="publisher" itemscope="" itemtype="http://schema.org/Organization"> <meta itemprop="name" content="Ticketstoday"> </span> <img id="review-avatar" src="http://ticketstoday.local//images/avatar.svg" alt="" class="circle"> <div itemprop="author" itemscope="" itemtype="https://schema.org/Person"> <span class="title" itemprop="name">Ms. A Gunn</span> </div> <span class="grey-text text-darken-1">Feb 3, 2019</span> <div> <span class="stars" data-rating="5" data-num-stars="5"><i class="material-icons">star</i><i class="material-icons">star</i><i class="material-icons">star</i><i class="material-icons">star</i><i class="material-icons">star</i></span> </div> <p itemprop="reviewBody">Test Review</p> </li> </ul> </div> </div> </div> </div> </main>
3 Réponses :
Vous pouvez ajouter le Avis
au Produit
avec le review propriété:
<li itemprop="review" itemscope itemtype="http://schema.org/Review">
Si vous faites cela, il n'est pas nécessaire de fournir la Propriété itemReviewed
.
L'élément:
<li class="collection-item avatar" itemprop="review" itemscope="" itemtype="http://schema.org/Review">
n'a pas l'attribut itemprop, il devrait être
<li class="collection-item avatar" itemscope="" itemtype="http://schema.org/Review">
dans ce cas.
Vérifiez-le maintenant, vous comprendrez comment cela fonctionne.
<div itemprop="review" itemtype="http://schema.org/Review" itemscope> <div itemprop="author" itemtype="http://schema.org/Person" itemscope> <meta itemprop="name" content="Author Name" /> //just for example, you will place your own author name here. </div>