2015-08-11 7 views
0

Следующий (сокращенный) скрипт возвращает 2 ошибки в Google's Structured Data Testing Tool, и я не знаю почему. Я следовал примеру кода от here, но почему-то он не работает.Инструмент тестирования структурированных данных с ошибками

<!DOCTYPE HTML> 
<html> 
    <body> 
     <div xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" 
      xmlns:rdfs="http://www.w3.org/2000/01/rdf-schema#" 
      xmlns="http://www.w3.org/1999/xhtml" 
      xmlns:foaf="http://xmlns.com/foaf/0.1/" 
      xmlns:gr="http://purl.org/goodrelations/v1#" 
      xmlns:xsd="http://www.w3.org/2001/XMLSchema#" 
      xmlns:review="http://purl.org/stuff/rev#" 
      xmlns:v="http://rdf.data-vocabulary.org/#"> 
      <div typeof="gr:Offering" about="#offeringdata"> 
       <div rel="foaf:page" resource=""></div> 
       <div rev="gr:offers" resource="#companydata"></div> 
       <div property="gr:name" content="" ></div> 
       <div property="gr:description" content="" ></div> 
       <div property="gr:hasStockKeepingUnit" content="" datatype="xsd:string"></div> 
       <div rel="gr:includes"> 
        <div typeof="gr:SomeItems" about="#productdata"> 
         <div property="gr:name" content="" ></div> 
         <div property="gr:description" content="" ></div> 
         <div rel="foaf:depiction v:image" resource=""></div> 
         <div property="gr:hasStockKeepingUnit" content="" datatype="xsd:string"></div> 
         <div property="gr:category" content="" ></div> 
        </div> 
       </div> 
       <div rel="gr:hasPriceSpecification"> 
        <div typeof="gr:UnitPriceSpecification"> 
         <div property="gr:validFrom" content="2015-08-11T16:34:02Z" datatype="xsd:dateTime"></div> 
         <div property="gr:validThrough" content="2015-08-11T16:34:02Z" datatype="xsd:dateTime"></div> 
         <div property="gr:hasUnitOfMeasurement" content="C62" datatype="xsd:string"></div> 
         <div property="gr:hasCurrency" content="EUR" datatype="xsd:string"></div> 
         <div property="gr:hasCurrencyValue" content="95.8" datatype="xsd:float"></div> 
        </div> 
       </div> 
       <div property="gr:validFrom" content="2015-08-11T16:34:02Z" datatype="xsd:dateTime"></div> 
       <div property="gr:validThrough" content="2015-08-11T16:34:02Z" datatype="xsd:dateTime"></div> 
       <div property="gr:eligibleRegions" content="AD" datatype="xsd:string"></div> 
       <div property="gr:eligibleRegions" content="BE" datatype="xsd:string"></div> 
       <div property="gr:eligibleRegions" content="BG" datatype="xsd:string"></div> 
       <div property="gr:eligibleRegions" content="DK" datatype="xsd:string"></div> 
       <div property="gr:eligibleRegions" content="DE" datatype="xsd:string"></div> 
       <div property="gr:eligibleRegions" content="EE" datatype="xsd:string"></div> 
       <div property="gr:eligibleRegions" content="FI" datatype="xsd:string"></div> 
       <div property="gr:eligibleRegions" content="FR" datatype="xsd:string"></div> 
       <div property="gr:eligibleRegions" content="GR" datatype="xsd:string"></div> 
       <div property="gr:eligibleRegions" content="VA" datatype="xsd:string"></div> 
       <div property="gr:eligibleRegions" content="IE" datatype="xsd:string"></div> 
       <div property="gr:eligibleRegions" content="IT" datatype="xsd:string"></div> 
       <div property="gr:eligibleRegions" content="HR" datatype="xsd:string"></div> 
       <div property="gr:eligibleRegions" content="LV" datatype="xsd:string"></div> 
       <div property="gr:eligibleRegions" content="LI" datatype="xsd:string"></div> 
       <div property="gr:eligibleRegions" content="LT" datatype="xsd:string"></div> 
       <div property="gr:eligibleRegions" content="LU" datatype="xsd:string"></div> 
       <div property="gr:eligibleRegions" content="MT" datatype="xsd:string"></div> 
       <div property="gr:eligibleRegions" content="MC" datatype="xsd:string"></div> 
       <div property="gr:eligibleRegions" content="NL" datatype="xsd:string"></div> 
       <div property="gr:eligibleRegions" content="NO" datatype="xsd:string"></div> 
       <div property="gr:eligibleRegions" content="AT" datatype="xsd:string"></div> 
       <div property="gr:eligibleRegions" content="PL" datatype="xsd:string"></div> 
       <div property="gr:eligibleRegions" content="PT" datatype="xsd:string"></div> 
       <div property="gr:eligibleRegions" content="RO" datatype="xsd:string"></div> 
       <div property="gr:eligibleRegions" content="SM" datatype="xsd:string"></div> 
       <div property="gr:eligibleRegions" content="SE" datatype="xsd:string"></div> 
       <div property="gr:eligibleRegions" content="CH" datatype="xsd:string"></div> 
       <div property="gr:eligibleRegions" content="SK" datatype="xsd:string"></div> 
       <div property="gr:eligibleRegions" content="SI" datatype="xsd:string"></div> 
       <div property="gr:eligibleRegions" content="ES" datatype="xsd:string"></div> 
       <div property="gr:eligibleRegions" content="CZ" datatype="xsd:string"></div> 
       <div property="gr:eligibleRegions" content="HU" datatype="xsd:string"></div> 
       <div property="gr:eligibleRegions" content="GB" datatype="xsd:string"></div> 
       <div property="gr:eligibleRegions" content="CY" datatype="xsd:string"></div> 
       <div rel="gr:acceptedPaymentMethods" resource="http://purl.org/goodrelations/v1#COD"></div> 
       <div rel="gr:acceptedPaymentMethods" resource="http://purl.org/goodrelations/v1#VISA"></div> 
       <div rel="gr:acceptedPaymentMethods" resource="http://purl.org/goodrelations/v1#MasterCard"></div> 
       <div rel="gr:acceptedPaymentMethods" resource="http://purl.org/goodrelations/v1#ByBankTransferInAdvance"></div> 
       <div rel="gr:acceptedPaymentMethods" resource="http://purl.org/goodrelations/v1#ByInvoice"></div> 
       <div rel="gr:acceptedPaymentMethods" resource="http://purl.org/goodrelations/v1#DirectDebit"></div> 
       <div rel="gr:acceptedPaymentMethods" resource=""> 
       </div> 
       <div rel="gr:acceptedPaymentMethods" resource="http://purl.org/goodrelations/v1#DirectDebit"></div> 
       <div rel="gr:acceptedPaymentMethods" resource=""> 
       </div> 
       <div rel="gr:acceptedPaymentMethods" resource=""> 
       </div> 
       <div rel="gr:availableDeliveryMethods" resource="http://purl.org/goodrelations/v1#DeliveryModeFreight"></div> 
       <div rel="gr:availableDeliveryMethods" resource="http://purl.org/goodrelations/v1#DeliveryModeFreight"></div> 
       <div rel="gr:availableDeliveryMethods" resource="http://purl.org/goodrelations/v1#DeliveryModeFreight"></div> 
       <div rel="gr:availableDeliveryMethods" resource="http://purl.org/goodrelations/v1#DeliveryModeFreight"></div> 
       <div rel="gr:availableDeliveryMethods" resource="http://purl.org/goodrelations/v1#DeliveryModeFreight"></div> 
       <div rel="gr:hasPriceSpecification" resource=""></div> 
       <div rel="gr:hasPriceSpecification" resource=""></div> 
       <div rel="gr:hasPriceSpecification" resource=""></div> 
       <div rel="gr:hasPriceSpecification" resource=""></div> 
       <div rel="gr:hasPriceSpecification" resource=""></div> 
       <div rel="gr:hasPriceSpecification" resource=""></div> 
       <div rel="gr:hasPriceSpecification" resource=""></div> 
       <div rel="gr:hasPriceSpecification" resource=""></div> 
       <div rel="foaf:depiction v:image" resource=""></div> 
      </div> 
     </div> 
    </body> 
</html> 

Кто-нибудь знает почему?

ответ

0

Вы используете инструмент Google Structured Data Testing Tool, который ожидает словарь http://schema.org, в то время как вы используете словарь Good Relations. Определения GR были опубликованы в 2011 году, а в ноябре 2012 года словарь Good Relations был добавлен в выпуск Schema.org v0.99. Объявление http://blog.schema.org/2012/11/good-relations-and-schemaorg.html. Примите словарный запас Schema.org, и вы получите гораздо лучшие результаты с помощью Google SDTT.

 Смежные вопросы

  • Нет связанных вопросов^_^