Загвар:ЭлементШалгах/doc
Appearance
Энэ нь Загвар:ЭлементШалгах хуудсын баримт бичгийн дэд хуудас юм. Энэ нь хэрэглээний мэдээлэл, ангиллууд болон анхны загвар page хуудасны нэг хэсэг биш бусад мэдээллийг агуулсан болно. |
Template that returns an error message if the first argument is not valid for use with other nuclide templates helper templates.
Usage
[кодоор засварлах]When using a string that is not a valid element name or symbol or "x" or "element", an error message is returned, like so:
{{CheckElement|C}}
will return "Загвар:CheckElement"{{CheckElement|Carbon}}
will return "Загвар:CheckElement"{{CheckElement|Blablabla}}
will return "Загвар:CheckElement"
The "link=yes" argument is also supported; if the element name or symbol has no associated link, an error message is returned, like so:
{{CheckElement|link=yes|C}}
will return "Загвар:CheckElement"{{CheckElement|link=yes|Carbon}}
will return "Загвар:CheckElement"{{CheckElement|link=yes|X}}
will return "Загвар:CheckElement"
When using a common name for an element that goes against the Wikipedia style guide for element names, a warning message will be returned. There are currently three such names:
{{CheckElement|Aluminum}}
will return "Загвар:CheckElement"{{CheckElement|Sulphur}}
will return "Загвар:CheckElement"{{CheckElement|Cesium}}
will return "Загвар:CheckElement"
This template can be used in other templates to check for error before calling other templates that require a valid element or symbol like so:
{{#ifexpr:{{CheckElement|{{{element argument}}}|link={{{link|}}} }} | {{Element|{{{element argument}}} }} is the best element in the whole world | Bad input for element name or symbol }}
Мөн үзэх
[кодоор засварлах]- {{ЭлементЛинк}}
- {{ЭлементТэмдэг}}
- {{ЭлементПротон}}
- {{ЭлементНейтрон}}