TPAC discoverability: include Open Graph Protocol markup for bonus points

Bug #1423585 reported by Dan Scott on 2015-02-19
This bug affects 1 person
Affects Status Importance Assigned to Milestone

Bug Description

* Evergreen master

Shockingly, some clients do not grok markup. That's okay, there's another much lighter form of markup designed to facilitate social sharing: Open Graph Protocol (documented at And they can co-exist. We simply have to add a few <meta> tags to the <head> of the record detail pages, largely reusing what we already have.

Dan Scott (denials) wrote :

See;a=shortlog;h=refs/heads/user/dbs/lp1423585_open_graph_protocol for a working branch that adds rudimentary Open Graph Protocol markup to record detail pages and library pages.

We also change the simplistic "metalinks" scalar variable into a ctx.metalinks list variable so that we can iterate over it and ensure that it's available to populate on every page in the TPAC.

tags: added: pullrequest
Changed in evergreen:
milestone: none → 2.8-beta
Galen Charlton (gmc) on 2015-02-20
Changed in evergreen:
assignee: nobody → Galen Charlton (gmc)
Galen Charlton (gmc) wrote :

When I ran a record page through the Facebook Open Graph Object Debugger, it complained:

Object at URL '' is invalid because the configured 'og:type' of '' is invalid.

I then tried it with:

<head prefix="og: s:">
<meta property="og:type" content="s:Book">

and it didn't like that either.

Do you have any guidance? Not necessary the end of the world if FB doesn't like that way of extending og:type but other consumers will accept it... but I guess I'd like some assurance that other consumers would.

Dan Scott (denials) wrote :

The list of types at is extremely limited. We could special case a "if schema book, then just book" but I highly doubt it's worth it. Otherwise, outside of video, music, article, and book, everything is a website. That's just dumb.

And, really, most sharing sites only care about title, image, and url, because the OGP types are almost useless. In the end, OGP is RDFa, so types are technically valid, and I'd rather express the greater richness of here.

Dan Scott (denials) wrote :

Oh, and Facebook's own docs say: "You can also specify your own types via Open Graph."

So that's what we're doing. If you want to see a better making of schema types to the native available OGP types, I could consider that an acceptable bug. But I don't think it's a necessary precondition for merging.

Galen Charlton (gmc) wrote :

I'm not seeing examples of arbitrary URIs as og:type values, either in this Facebook example of creating a custom type:

(where apparently singular and plural nouns are preferred)

or this more worked out example:

But I'm willing to accept either that it doesn't matter for most consumers or that if it turns out that OpenGraph consumers really prefer CURIEs for types, that we'll put that in later.

Consequently, I'll write up a release note blurb and push.

Galen Charlton (gmc) wrote :

And pushed. Thanks, Dan.

(Though I must confess to some qualms about what richer RDFa markup would mean if ever we added a Facebook "Like" button to the record details page.)

Changed in evergreen:
status: New → Fix Committed
Changed in evergreen:
status: Fix Committed → Fix Released
assignee: Galen Charlton (gmc) → nobody
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers