Template:FXConvert/doc

Purpose
The purpose of this template is to automatically convert and format currency applying adjustment for inflation where appropriate. Rates of exchange and inflation must be manually copied by editors in the supporting templates therefore this template's output does not necessarily reflect the present exchange rates or price indices but, rather, reflects the rates and indices at the time of the last update.

The default target currency (USD at present) may change in the future. Currently, only the Euro is also supported.

Parameters
A description of the template's parameters are listed below.

TemplateData
{	"params": { "1": {                       "aliases": [ "country" ],			"label": "country code", "description": "ISO 3166-1 alpha-3 country code of the currency to be converted, e.g. DEU (Germany, Euro since the year 2000).", "example": "GBR", "type": "line", "required": true },		"2": {			"label": "Value", "description": "The value, in the source, that needs to be converted. The template will not accept pre-formatted values (i.e. 1,234).", "example": "500000000", "type": "number", "required": true },		"3": {			"label": "Currency units", "description": "Use this to represent larger numbers such as crores, billions et al.", "example": "c, lc, b, m, k, cr, p, pa, po, ba", "type": "line", "suggested": true },               "cur": { "label": "Currency code", "description": "It allows to select the currency for the country. Currently only supported for the Euro and the currencies that have been immediately replaced by the Euro.", "example": "FRF, EUR", "type": "line" },               "cursign": { "label": "Currency sign", "description": "This provides a currency sign for the original and inflated (without conversion) values. If the argument is not present they will be shown without one.", "example": "£", "type": "content", "suggested": true },               "infsign": { "label": "Inflated sign", "description": "This provides a currency sign for the inflated (without conversion) value. If the argument is not present, cursign will be looked for.", "example": "£", "type": "content", "suggested": false },		"lk": { "label": "Linking", "description": "Gives option to whether link currency names (paise, etc.) or number names (crores, lakhs, billions, trillions)", "example": "on, off, source, original, inflated, result, converted, source-converted", "type": "line", "suggested": true },		"year": { "description": "This parameter allows for inflation. Historic values will be inflated to the most current values available then converted.", "example": "2015", "label": "Year", "type": "number", "suggested": true },               "index": { "description": "This parameter allows for inflation. Historic values will be inflated to the latest year available in Inflation then converted.", "example": "UK-GDP", "label": "Index", "type": "line", "suggested": false },		"to": { "description": "This parameter allows for conversion to various different currencies. The USD (default) and the euro are currently supported.", "example": "EUR", "default": "USD", "label": "To" },               "r": { "label": "Rounding digits", "description": "Used to round significant digits. A value of \"0\" will drop paise or cent values from the converted number. By default the conversion will be rounded to two significant figures.", "example": "0", "type": "number" },               "force": { "label": "Force", "description": "This parameter allows to force a conversion at the most current rate available when data is lacking for the provided year when its value is \"yes\".", "example": "yes", "type": "line" },               "exact": { "label": "Exact", "description": "This provides some control over formatting. \"source\" requests to display the input value normally (in American fashion) after applying the units. \"on\" does this for both the input and result values. Otherwise all values will be displayed as per Format price.", "example": "source, on", "type": "line" },       "showdate": { "label": "Show date", "description": "This allows to disable displaying the original year.", "example": "no", "type": "line" },               "ref": { "label": "References", "description": "This allows displaying one or more references next to the original value. Each one must consist of a ref wikitext element.", "example": " ", "type": "content", "suggested": true },               "mode": { "description": "This parameter allows for the control of the output mode. Currently, blank (default) and historical are supported. In historical mode, conversions are performed using a historical exchange rate, for the year supplied.", "example": "historical", "default": "(blank)", "label": "Mode", "type": "line" },               "convert": { "description": "This parameter controls the currency conversion. Setting it to blank or omitting it results in the default mode. Setting it to  disables it.", "example": "no", "default": "(blank)", "label": "Convert", "type": "line" }	},	"paramOrder": [ "1",		"2",               "3",                "cur", "cursign", "infsign", "lk", "year", "index", "to", "r", "force", "exact", "showdate", "ref", "mode", "convert" ],	"description": "Template calculates a value of a currency, which you can enter, to another currency and then presents the results." }