duration

From IndieWeb


duration is an emerging microformats2 property that indicate the time duration of audio and/or video properties in the same item. length is an alias.

Examples in the wild have used both ISO 8601 duration (eg P1DT5H0M6S) values and integer seconds values.

How to

How to publish

Use a data element with either integer number of seconds or ISO 8601 duration in the value attribute, and any human-readable representation you choose in the contents. Example:

<data class="p-duration" value="PT1H7M59S">1h 8m</data>

IndieWeb Examples

Services

Granary

Main article: granary

granary converts podcast h-feeds and h-entries to RSS with enclosures, including iTunes extension elements.

It reads episode duration from the duration and length mf2 properties, and supports both integer seconds and ISO 8601 duration values. It emits the duration mf2 property with integer seconds value. Background discussion.