Or, in the case of multiple badges per page, it could be done via a data-assertion attribute on an <img> or <div> element. Or something else.
This has a number of benefits:
It would allow users to simply think of a badge or badge-group as the URL of the human-readable version of the web page containing their badge(s). They could then just paste the page's URL into a backpack or other badge tool.
It would allow search engines and other computerized agents to glean information about the badge(s) on a page without having to manually download and inspect every image on the page to see if it's baked.
Baking an assertion URL into a HTML page via a <link> tag or some kind of data- attribute arguably requires less technical expertise and server-side storage than baking a PNG.
Note that this proposal is distinct from a HTML Microformat for Open Badges, which prescribes a way to encapsulate all the information about a badge/class/issuer in HTML. The proposal described here merely prescribes a way to associate a web page with one or more JSON assertions.
An alternative to this proposal might be to somehow merge it with #1, so that the same specification could be used to advertise the badge classes an issuer provides and associate issued badges with a web page. But that might be trying to kill too many birds with one stone.
I think it would be really great if badges could be baked into HTML pages, or even if multiple badges could be baked into a single HTML page.
This could be done via a
<link>
tag in the document header, e.g.:Or, in the case of multiple badges per page, it could be done via a
data-assertion
attribute on an<img>
or<div>
element. Or something else.This has a number of benefits:
<link>
tag or some kind ofdata-
attribute arguably requires less technical expertise and server-side storage than baking a PNG.Note that this proposal is distinct from a HTML Microformat for Open Badges, which prescribes a way to encapsulate all the information about a badge/class/issuer in HTML. The proposal described here merely prescribes a way to associate a web page with one or more JSON assertions.
An alternative to this proposal might be to somehow merge it with #1, so that the same specification could be used to advertise the badge classes an issuer provides and associate issued badges with a web page. But that might be trying to kill too many birds with one stone.