This is the ambox or article message box meta template.
This வார்ப்புரு 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. You can conduct experiments, and should test all major changes, in either this template's sandbox, the general template sandbox, or your user space before changing anything here. |
It is used to create article message box templates such as {{wikify}} etc. It offers several different colours, uses default images if no image parameter is given and it has some other features.
This meta template is just a thin wrapper for the ambox CSS classes in MediaWiki:Common.css. The classes can also be used directly in a wikitable table-responsive , especially if special functionality is needed. See the how-to guide for that.
Simple usage example:
{{ambox | text = Some text.}}
Complex example:
{{ambox | type = style | image = [[Image:Icon apps query.svg|38px]] | style = width: 400px; color: red; font-weight: bold; font-style: italic | text = The message body text. }}
The message body text. |
The following examples use different type parameters but use no image parameters thus they use the default images for each type.
The default images shown above are mostly for convenience. In many cases it is more appropriate to use more specific images. These examples use the image parameter to specify an image other than the default images.
type = content image = [[Image:Unbalanced scales.svg|40px]] This image is often used for {{POV}} and similar issues. |
Some other parameter combinations.
List of all parameters:
{{ambox | type = serious / content / style / merge / notice | image = none / blank / [[Image:Some image.svg|40px]] | imageright = [[Image:Some image.svg|40px]] | style = Cascading Style Sheets value | text = The message body text. }}
type
image
[[Image:Unbalanced scales.svg|40px]]
imageright
[[Image:Nuvola apps bookcase.png|40px]]
style
...
text
If you need to use special characters in the text parameter then you need to escape them like this:
{{ambox | text =Equal sign = and a start and end brace { } work fine as they are. But here is a pipe {{!}} and two end braces}}}} . And now a pipe and end braces|}} .
This template uses CSS classes for most of its looks, thus it is fully skinnable.
Internally this meta template uses HTML markup instead of wiki markup for the table code. That is the usual way we make meta templates since wiki markup has several drawbacks. For instance it makes it harder to use parser functions and special characters in parameters.
For more technical details see the talk page and the "See also" links below.