Print

Print


Hey, this is something I am interested in :)

On Mon, Feb 17, 2014 at 5:16 PM, Michael Schofield <[log in to unmask]>wrote:

> Back in October, Sean Hannan (@MrDys), Dan Scott (@denials), John Fink
> (@adr), and me (@gollydamn) talked about this on twitter and I'll see if I
> can track down the whole conversation. I'm not sure there's a de facto
> this-is-how-it-must-be-done, at least not yet, and there are definitely
> more correct examples than mine. In fact, mine's a little half-assed and
> less informed than what these other three could [or have] spun up. Sorry if
> the markup looks a little jacked courtesy of email formatting. Here's what
> your hours might look like for just Monday through Wednesday, assuming the
> actual hours are generated by a script (i.e., Matt Reidsma's Hours Script [
> https://github.com/mreidsma/Today-s-Hours]):
>
> <aside itemscope itemtype="http://schema.org/LocalBusiness">
>
>   <time itemprop="openingHoursSpecification" datetime="Mo 07:30-23:00, Tu
> 11:00-22:00, We 09:00-14:00">
>
>   <ul>
>     <li itemprop="DayOfWeek">Monday: </li>
>     <li itemprop="DayOfWeek">Tuesday: </li>
>     <li itemprop="DayOfWeek">Wednesday: </li>
>   </ul>
> </time>
>
> </aside>
>

Mmm, that example doesn't look valid for
http://schema.org/openingHoursSpecification actually; it would fit for
http://schema.org/openingHours though (yes, this openingHours vs.
openingHoursSpecification thing is confusing!).

Evergreen will publish library hours by default as of 2.6 (because, you
know, your library system already knows your opening hours for circulation
purposes, and other library-specific info; why not publish that as
structured data?). So hopefully Google will take note of that for the
thousand-odd Evergreen libraries that will start publishing this data as
they upgrade to 2.6 in the future...

Here's a link to an example of what that info page looks like currently
(modulo some CSS):
http://stuff.coffeecode.net/schema.org/evergreen/library/BR1

Dig into the "Opening hours" section and you'll see:

    <h2>Opening hours</h2>
    <div class="opening-hours" property="openingHoursSpecification"
typeof="OpeningHoursSpecification">
        <link property="dayOfWeek" href="
http://purl.org/goodrelations/v1#Monday" />Monday:
        <span property="opens">09:00</span>-<span
property="closes">17:00</span>
    </div>

... etc ..

I much prefer the http://schema.org/OpeningHoursSpecification enumerated
type vs. the openingHours property, as the former breaks things down into
understandable chunks for tiny brains like mine.

That said, whether Google, Yandex, Bing, or anything else actually will use
the marked up hours in either format is entirely a mug's game. Maybe, maybe
not; if your library has a G+ Places page then it might pull the hours from
there, instead. There are absolutely no guarantees about what search
engines will or will not use :)

Hope this helps,
Dan