Template:Ft to M

From Citizendium
Revision as of 00:27, 15 June 2009 by imported>Drew R. Smith (New page: <includeonly>{{#ifexpr:({{#if:{{{1|}}}|1|0}} OR {{#if:{{{num|}}}|1|0}} OR {{#if:{{{l|}}}|1|0}} OR {{#if:{{{from|}}}|1|0}})|{{#ifexpr:({{#if:{{{2|}}}|1|0}} OR {{#if:{{{w|}}}|1|0}} OR {{#if:...)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search
This template employs intricate features of template syntax.
You are encouraged to familiarise yourself with its setup and parser functions before editing the template.
If your edit causes unexpected problems, please undo it quickly, as this template may appear on a large number of pages.
Remember that you can and should conduct experiments and test improvements in your user space before changing anything here.
This documentation is transcluded from Template:Ft to M/doc (edit | history)


This template is intended to perform foot-to-meter conversions. It converts single values, ranges, as well as two- and three-dimensional measurements.

Accepted parameters

Italicized parameters are optional:

  • num, or l (length), or from, or first unnamed parameter is a required parameter, which specifies the number of Feet to be converted to meters (for single value conversions), or length (for two- and three-dimensional conversions), or start of range (for range conversions). Please do not format this parameter; i.e., use 1234 instead of 1,234.
  • w (width), or to, or second unnamed parameter is a parameter specifying width (for dimensional conversions) or end of range (for range conversions) in Feet to be converted to meters. Please do not format this parameter; i.e., use 1234 instead of 1,234.
  • h (height) or third unnamed parameter is a parameter specifying height (for three-dimensional conversions) in Feet to be converted to meters. Please do not format this parameter; i.e., use 1234 instead of 1,234.
  • convtype (conversion type) can take values of either range or dim. Range is only meaningful when two values are supplied for conversion. The default value is dim.
  • abbr can take values of either mos, yes, or no. Mos will show the names of the units (Feet, M); yes will show the abbreviated names of the units (Ft, M); and no will show the full names of the units (Feet, meters). With dimensional conversions, all values will be separated with the "by" preposition when the parameter is set to no, and with the "×" sign when the parameter is set to yes. When the parameter is set to mos, foot values will be separated with the "by" preposition, and the converted values in meters—with the "×" sign. The default value is mos.
  • spell can take values of American or Commonwealth and is only meaningful when abbr is set to no. American will use "meters", and Commonwealth—"metres". The default value is American.
  • precision is the number of decimal digits in the converted value. The default value is 0 for converted values equal or more than 10 and 1 for converted values of less than 10.
  • wiki specifies whether the names of the units should be wikified or not and can take values of either yes or no. The default value is no.

Capitalization of the parameters is unimportant.

Usage and examples

Single value conversion

Usage
{{Ft to M | num | abbr | spell | precision | wiki}}
Examples
{{Ft to M|1}} → 1 feet (0.3 M)
Short notation: {{Ft to M|1|abbr=yes}} → 1 Ft (0.3 M)
Full notation: {{Ft to M|num=1|abbr=no|spell=Commonwealth|precision=2|wiki=yes}} → 1 feet (0.3 metres)

Range conversions

Usage
{{Ft to M | from | to | convtype | abbr | spell | precision | wiki}}
Examples
{{Ft to M|10|20|convtype=range}} → 10–20 feet (3–6.1 M)
Short notation: {{Ft to M|10|20|convtype=range|abbr=yes}} → 10–20 Ft (3–6.1 M)
Full notation: {{Ft to M|from=10|to=20|convtype=range|abbr=no|spell=Commonwealth|precision=1|wiki=yes}} → 10–20 feet (3–6.1 metres)

Two-dimensional conversions

Usage
{{Ft to M | l | w | convtype | abbr | spell | precision | wiki}}
Examples
{{Ft to M|10|20}} → 10 Feet by 20 Feet (3 M × 6.1 M)
Short notation: {{Ft to M|10|20|abbr=yes}} → 10 Ft × 20 Ft (3 M × 6.1 M)
Full notation: {{Ft to M|l=10|w=20|convtype=dim|abbr=no|spell=Commonwealth|precision=1|wiki=yes}} → 10 Feet by 20 Feet (3 metres by 6.1 metres)

Three-dimensional conversions

Usage
{{Ft to M | l | w | h | convtype | abbr | spell | precision | wiki}}
Examples
{{Ft to M|1|2|3}} → 1 Foot by 2 Feet by 3 Feet (0.3 M × 0.6 M × 0.9 M)
Short notation: {{Ft to M|1|2|3|abbr=yes}} → 1 Ft × 2 Ft × 3 Ft (0.3 M × 0.6 M × 0.9 M)
Full notation: {{Ft to M|l=1|w=2|h=3|convtype=dim|abbr=no|spell=Commonwealth|precision=2|wiki=yes}} → 1 Foot by 2 Feet by 3 Feet (0.3 metres by 0.61 metres by 0.91 metres)

</noinclude>

See also