This template emits the hAudio microformat.

Usage

uredi

Unformatted input

uredi

An unformatted duration can be input in the first parameter: {{Duration|10:20:30}} (hours:minutes:seconds) or {{Duration|20:30}} (minutes:seconds). There must be a seconds value, as inputs in hours and minutes are indistinguishable from inputs in minutes and seconds.

Numbered parameters

uredi
{{Duration|10|20|30}}

where parameters are hours, minutes and seconds respectively. If the hours or minutes values are zero, then leave them blank (e.g. {{Duration||20|30}}). Minutes and seconds values default to zero, although they should ideally be specified.

h, m and s parameters

uredi
{{Duration|h=10|m=20|s=30}}

where h, m and s are hours, minutes and seconds respectively. Minutes and seconds values default to zero, although they should ideally be specified.

Parent templates

uredi

This template can be used in:

In {{Infobox album}}, the microformat is added automatically if there is not one already. However, more complicated values might require this template.

Examples

uredi

Unformatted input

uredi
  • {{Duration|1:22:34}} renders as: 1:22:34
  • {{Duration|74:32}} renders as: 74:32
  • {{Duration|1:02:34}} renders as: 1:02:34
  • {{Duration|1:2:3}} renders as: 1:02:03
  • {{Duration|0:22:34}} renders as: 0:22:34
  • {{Duration|0:0:34}} renders as: 0:00:34
  • {{Duration|0:34}} renders as: 0:34

h, m and s parameters

uredi
  • {{Duration|h=1|m=22|s=34}} renders as: 1:22:34
  • {{Duration|m=74|s=32}} renders as: 74:32
  • {{Duration|m=2|s=34}} renders as: 2:34
  • {{Duration|h=1|s=34}} renders as: 1:00:34
  • {{Duration|h=1}} renders as: 1:00:00
  • {{Duration|h=0|m=22|s=34}} renders as: 0:22:34
  • {{Duration|h=0|m=0|s=34}} renders as: 0:00:34
  • {{Duration|h=1|m=22|s=34.5678}} renders as: 1:22:34.5678
  • {{Duration|h=1|m=22|s=3}} renders as: 1:22:03
  • {{Duration|h=1|m=2|s=34}} renders as: 1:02:34
  • {{Duration|h=1|m=2|s=3}} renders as: 1:02:03
  • {{Duration|h=1|m=2}} renders as: 1:02:00
  • {{Duration|s=34}} renders as: 0:34
  • {{Duration|m=0|s=34}} renders as: 0:34
  • {{Duration|h=1|m=0|s=34}} renders as: 1:00:34
  • {{Duration|h=1|m=22|s=0}} renders as: 1:22:00
  • Rdeči XN {{Duration|h=one|m=22|s=0}} renders as: Napaka v Modul:Duration: Invalid values
  • Rdeči XN {{Duration|h=1|m=22|s=78}} renders as: Napaka v Modul:Duration: Seconds value must be less than 60
  • Rdeči XN {{Duration|h=1.1|m=2.2}} renders as: Napaka v Modul:Duration: Hours and minutes values must be integers

Numbered parameters

uredi
  • {{Duration|1|22|34}} renders as: 1:22:34
  • {{Duration||74|32}} renders as: 74:32
  • {{Duration|1|2|34}} renders as: 1:02:34
  • {{Duration|1|2|3}} renders as: 1:02:03
  • {{Duration|0|22|34}} renders as: 0:22:34
  • {{Duration|0|0|34}} renders as: 0:00:34
  • {{Duration||0|34}} renders as: 0:34
  • {{Duration|||34}} renders as: 0:34
  • {{Duration|1|22|34.5678}} renders as: 1:22:34.5678
  • {{Duration||1|22}} renders as: 1:22
  • {{Duration|1|22}} renders as: 1:22:00
  • {{Duration|1|22|0}} renders as: 1:22:00
  • Rdeči XN {{Duration|1|22|}} renders as: 1:22:00
  • {{Duration|0|0|0}} renders as: (blank)
  • {{Duration|||}} renders as: (blank)
  • Rdeči XN {{Duration|1|22|34|55}} renders as: Napaka v Modul:Duration: Parameter number 4 should not be specified
  • Rdeči XN {{Duration|one|22|0}} renders as: Napaka v Modul:Duration: Invalid values
  • Rdeči XN {{Duration|1|22|78}} renders as: Napaka v Modul:Duration: Seconds value must be less than 60
  • Rdeči XN {{Duration|1.1|2.2}} renders as: Napaka v Modul:Duration: Hours and minutes values must be integers

Microformat

uredi

HTML-označevanje, ki ga ustvari ta predloga, vključuje HTML classes intended to be part of an hAudio microformat, ki omogoča preprosto razčlenitev an audio recording's details računalniškim programom. To pomaga pri opravilih, kot sta katalogizacija člankov in vzdrževanje podatkovnih zbirk.

Uporabljeni razredi

HTML-razredi tega mikroformata vključujejo:

  • fn
  • album
  • description
  • category
  • contributor
  • duration
  • h
  • item
  • min
  • photo
  • position
  • price
  • published
  • s
Prosimo, ne preimenujte in ne odstranite teh razredov, prav tako pa ne strnite gnezdenih elementov, ki jih ustvarijo.

TemplateData

uredi
To je dokumentacija TemplateData za predlogo, ki jo uporabljajo Vizualni urejevalnik in druga orodja; glejte mesečno poročilo o uporabi parametrov za to predlogo.

TemplateData za Trajanje

For use in templates emitting the hAudio [[microformat]]

Parametri predloge[Urejanje podatkov predloge]

Za to predlogo se uporablja postavitev parametrov v eni vrstici.

ParameterOpisVrstaStanje
Hoursh 1

brez opisa

Zgled
3
Številkapredlagano
Minutesm 2

brez opisa

Zgled
32
Številkapredlagano
Secondss 3

brez opisa

Zgled
42
Številkapredlagano