Template:Period/Doc: Difference between revisions

From LifeWiki
Jump to navigation Jump to search
Created page with "This template can be used to quickly and easily embed a link to the category of oscillators with a given period. For example, :<tt><nowiki>The frobnozzle is a {{period|3}} ..."
 
Mention second parameter
Line 13: Line 13:
everytime you want to link to an oscillator period category.)
everytime you want to link to an oscillator period category.)


The template takes a single parameter, which can be passed without a name or as <tt>year=</tt>.
The template takes two parameters, the first of which is the period and can be passed without a name or as <tt>year=</tt>. The second one is passed without a name and removes the "period" from the resulting text:
 
:<tt><nowiki>The first known oscillators of periods {{period|37|brief}} and {{period|51|brief}} were found in 2009.</nowiki></tt>
 
becomes
 
:The first known oscillators of periods {{period|37|brief}} and {{period|51|brief}} were found in 2009.

Revision as of 13:37, 24 March 2019

This template can be used to quickly and easily embed a link to the category of oscillators with a given period. For example,

The frobnozzle is a {{period|3}} [[oscillator]].

becomes

The frobnozzle is a period-3 oscillator.

(This is much more than having to type the equivalent of

The frobnozzle is a [[period]] [[:Category:Oscillators with period 3|3]] [[oscillator]].

everytime you want to link to an oscillator period category.)

The template takes two parameters, the first of which is the period and can be passed without a name or as year=. The second one is passed without a name and removes the "period" from the resulting text:

The first known oscillators of periods {{period|37|brief}} and {{period|51|brief}} were found in 2009.

becomes

The first known oscillators of periods 37 and 51 were found in 2009.