I don't quite understand why some Schema.org examples use <meta> instead of say <span>. For example:

<meta itemprop="startDate" content="2016-04-21T20:00">
    Thu, 04/21/16
    8:00 p.m.

Source: https://schema.org/Event

If my current markup is:

<li>Jan 13-15, 2016</li>

Do I need to use meta or can I just add the Schema itemprop and content stuff inside the <li>? And what's the reason so I know when I will need to use the <meta>?


For Microdata, meta and link elements should be used if you don’t want to display the value of the property on your page.

This is typically the case for properties that expect a value that is not human-readable, for example URIs that represent accepted payment/delivery methods (= good case for link), or ISO 4217 codes that represent currencies (= good case for meta).

The example with the startDate property would ideally use the time element instead, as this is what should be used for dates/times, and it allows to specify the machine-readable format in the datetime attribute:

<time itemprop="startDate" datetime="2016-04-21T20:00">
    Thu, 04/21/16
    8:00 p.m.

For your own example, you could also use time elements, but because of your chosen format, it might not be very elegant:

  Jan <time itemprop="startDate" datetime="2016-01-13">13</time>-<time itemprop="endDate" datetime="2016-01-15">15</time>, 2016

The alternative with meta elements could look like:

  Jan 13-15, 2016 
  <meta itemprop="startDate" content="2016-01-13" /> 
  <meta itemprop="endDate" content="2016-01-15" />

Which one of those to use is a semantic markup question; it doesn’t affect the extracted Microdata/Schema.org.

|improve this answer|||||

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.