Difference between revisions of "Template:Audio/doc"
imported>Omegatron (←Created page with '<includeonly>{{template doc page transcluded}}</includeonly><noinclude>{{template doc page viewed directly}}</noinclude> <!-- EDIT TEMPLATE DOCUMENTATION BELOW THIS...') |
imported>MZMcBride (rm spaces) |
||
| Line 1: | Line 1: | ||
<includeonly>{{template doc page transcluded}}</includeonly><noinclude>{{template doc page viewed directly}}</noinclude> | <includeonly>{{template doc page transcluded}}</includeonly><noinclude>{{template doc page viewed directly}}</noinclude> | ||
<!-- EDIT TEMPLATE DOCUMENTATION BELOW THIS LINE --> | <!-- EDIT TEMPLATE DOCUMENTATION BELOW THIS LINE --> | ||
| − | |||
| − | |||
| − | |||
== Purpose == | == Purpose == | ||
| − | |||
This template links to an audio file for quick listening. It is meant to be used inline with text, for pronunciations and the like. | This template links to an audio file for quick listening. It is meant to be used inline with text, for pronunciations and the like. | ||
== Usage == | == Usage == | ||
| − | |||
<code><nowiki>{{Audio|name of sound file|text to use as link to soundfile}}</nowiki></code> | <code><nowiki>{{Audio|name of sound file|text to use as link to soundfile}}</nowiki></code> | ||
| Line 18: | Line 13: | ||
== Using on other wikis == | == Using on other wikis == | ||
| − | + | This is one of several templates that use [[CSS]] to format the template instead of containing all the formatting inline. '''It will not work on another wiki unless you copy both the template and the CSS rules.''' | |
| − | This is one of several templates that use [[CSS]] to format the template instead of containing all the formatting inline. | ||
This particular template depends on the "audiolink" css class to add the loudspeaker icon as a background image for the link, which allows it to be clicked and go to the same link destination instead of the image's description page. | This particular template depends on the "audiolink" css class to add the loudspeaker icon as a background image for the link, which allows it to be clicked and go to the same link destination instead of the image's description page. | ||
| Line 26: | Line 20: | ||
== See also == | == See also == | ||
| − | |||
* {{tl|Audio-nohelp}}, a variant of this template with no help links. | * {{tl|Audio-nohelp}}, a variant of this template with no help links. | ||
* {{tl|Audio-IPA}}, a variant of this template to be used with [[International Phonetic Alphabet|IPA]] notation. | * {{tl|Audio-IPA}}, a variant of this template to be used with [[International Phonetic Alphabet|IPA]] notation. | ||
| − | **{{tl|Audio-IPA-nohelp}}, a variant with no help links. | + | ** {{tl|Audio-IPA-nohelp}}, a variant with no help links. |
* {{tl|Spoken}}, which adds only the small icon with no links. | * {{tl|Spoken}}, which adds only the small icon with no links. | ||
* {{tl|Listen}}, which sets an audio clip off from the main text. | * {{tl|Listen}}, which sets an audio clip off from the main text. | ||
| Line 35: | Line 28: | ||
<includeonly> | <includeonly> | ||
<!-- ADD CATEGORIES BELOW THIS LINE --> | <!-- ADD CATEGORIES BELOW THIS LINE --> | ||
| − | |||
[[Category:Audio templates|{{PAGENAME}}]] | [[Category:Audio templates|{{PAGENAME}}]] | ||
<!-- ADD INTERWIKIS BELOW THIS LINE --> | <!-- ADD INTERWIKIS BELOW THIS LINE --> | ||
| − | |||
[[de:Vorlage:Audio]] | [[de:Vorlage:Audio]] | ||
[[bg:Шаблон:Audio]] | [[bg:Шаблон:Audio]] | ||
Revision as of 01:28, 12 September 2007
Template:Template doc page viewed directly
Contents
Purpose
This template links to an audio file for quick listening. It is meant to be used inline with text, for pronunciations and the like.
Usage
{{Audio|name of sound file|text to use as link to soundfile}}
Example:
'''Bordeaux''' ({{Audio|Fr-Bordeaux.ogg|pronunciation}}) is a [[Seaport|port]] city in...
gives this:
- Bordeaux (Audio file "Fr-Bordeaux.ogg" not found) is a port city in...
Using on other wikis
This is one of several templates that use CSS to format the template instead of containing all the formatting inline. It will not work on another wiki unless you copy both the template and the CSS rules.
This particular template depends on the "audiolink" css class to add the loudspeaker icon as a background image for the link, which allows it to be clicked and go to the same link destination instead of the image's description page.
These CSS rules are in MediaWiki:Common.css (the part that starts with .audiolink a {). You will need to get an administrator on your local wiki to add the rules to your site's CSS. (Likewise, tweaking the size and placement of the icon is done by changing the CSS; not the template itself.)
See also
- {{Audio-nohelp}}, a variant of this template with no help links.
- {{Audio-IPA}}, a variant of this template to be used with IPA notation.
- {{Audio-IPA-nohelp}}, a variant with no help links.
- {{Spoken}}, which adds only the small icon with no links.
- {{Listen}}, which sets an audio clip off from the main text.