FANDOM


Meta-template for building message boxes.

There are several sub-templates available for specific uses:

Usage

{{Mbox
|header        =Example header
|content       =Example text
|image         =Mbox default.svg
|border        =none
}}

Parameters

{{#vardefine:icon-highuse|}}{{#vardefine:icon-link|}}{{#vardefine:icon-image|Icon question.png}}{{#vardefine:icon-tooltip|Unrecognized icon name}}{{#vardefine:icon-size-word|normal}}{{#vardefine:icon-size|}}{{#vardefine:icon-image|Icon optional.png}}{{#vardefine:icon-tooltip|Optional}}{{#var:icon-tooltip}}[[{{#var:icon-link}}|​]]
(default: "gray")
border

Color of left border. Accepts standard HTML color names or RGB hex triplets. If set to "none", no colored border is displayed.

{{#vardefine:icon-highuse|}}{{#vardefine:icon-link|}}{{#vardefine:icon-image|Icon question.png}}{{#vardefine:icon-tooltip|Unrecognized icon name}}{{#vardefine:icon-size-word|normal}}{{#vardefine:icon-size|}}{{#vardefine:icon-image|Icon optional.png}}{{#vardefine:icon-tooltip|Optional}}{{#var:icon-tooltip}}[[{{#var:icon-link}}|​]]
bg

Color of box background. Accepts standard HTML color names or RGB hex triplets.

{{#vardefine:icon-highuse|}}{{#vardefine:icon-link|}}{{#vardefine:icon-image|Icon question.png}}{{#vardefine:icon-tooltip|Unrecognized icon name}}{{#vardefine:icon-size-word|normal}}{{#vardefine:icon-size|}}{{#vardefine:icon-image|Icon required.png}}{{#vardefine:icon-tooltip|Required}}{{#var:icon-tooltip}}[[{{#var:icon-link}}|​]]
content

Text content of the box, displayed below header and above footer.

{{#vardefine:icon-highuse|}}{{#vardefine:icon-link|}}{{#vardefine:icon-image|Icon question.png}}{{#vardefine:icon-tooltip|Unrecognized icon name}}{{#vardefine:icon-size-word|normal}}{{#vardefine:icon-size|}}{{#vardefine:icon-image|Icon optional.png}}{{#vardefine:icon-tooltip|Optional}}{{#var:icon-tooltip}}[[{{#var:icon-link}}|​]]
cssclass

Specifies additional CSS classes for the box.

{{#vardefine:icon-highuse|}}{{#vardefine:icon-link|}}{{#vardefine:icon-image|Icon question.png}}{{#vardefine:icon-tooltip|Unrecognized icon name}}{{#vardefine:icon-size-word|normal}}{{#vardefine:icon-size|}}{{#vardefine:icon-image|Icon optional.png}}{{#vardefine:icon-tooltip|Optional}}{{#var:icon-tooltip}}[[{{#var:icon-link}}|​]]
footer

Text in small font to be displayed below content.

{{#vardefine:icon-highuse|}}{{#vardefine:icon-link|}}{{#vardefine:icon-image|Icon question.png}}{{#vardefine:icon-tooltip|Unrecognized icon name}}{{#vardefine:icon-size-word|normal}}{{#vardefine:icon-size|}}{{#vardefine:icon-image|Icon optional.png}}{{#vardefine:icon-tooltip|Optional}}{{#var:icon-tooltip}}[[{{#var:icon-link}}|​]]
header

Main title/"headline" of the message box, displayed above content.

{{#vardefine:icon-highuse|}}{{#vardefine:icon-link|}}{{#vardefine:icon-image|Icon question.png}}{{#vardefine:icon-tooltip|Unrecognized icon name}}{{#vardefine:icon-size-word|normal}}{{#vardefine:icon-size|}}{{#vardefine:icon-image|Icon optional.png}}{{#vardefine:icon-tooltip|Optional}}{{#var:icon-tooltip}}[[{{#var:icon-link}}|​]]
image

File name of an image (without "File:") which should be displayed on the left side of the box.

{{#vardefine:icon-highuse|}}{{#vardefine:icon-link|}}{{#vardefine:icon-image|Icon question.png}}{{#vardefine:icon-tooltip|Unrecognized icon name}}{{#vardefine:icon-size-word|normal}}{{#vardefine:icon-size|}}{{#vardefine:icon-image|Icon optional.png}}{{#vardefine:icon-tooltip|Optional}}{{#var:icon-tooltip}}[[{{#var:icon-link}}|​]]
(default: "35x30px")
image size

Size of image in pixels.

Style parameters

All style options should be used sparingly as they can lead to visual inconsistencies. Some examples of useful styles:

  • Changing background color: background-color: #123456; (accepts HTML color names or RGB hex triplets)
  • Changing (horizontal) text-alignment: text-align: center; (accepts "center", "justify", "left", "right")
  • Changing vertical text-alignment: vertical-align: middle; (accepts "bottom", "middle", "top")


{{#vardefine:icon-highuse|}}{{#vardefine:icon-link|}}{{#vardefine:icon-image|Icon question.png}}{{#vardefine:icon-tooltip|Unrecognized icon name}}{{#vardefine:icon-size-word|normal}}{{#vardefine:icon-size|}}{{#vardefine:icon-image|Icon optional.png}}{{#vardefine:icon-tooltip|Optional}}{{#var:icon-tooltip}}[[{{#var:icon-link}}|​]]
body style

Specifies CSS styles to apply to the area containing content, header and footer (i.e. everything but image).

{{#vardefine:icon-highuse|}}{{#vardefine:icon-link|}}{{#vardefine:icon-image|Icon question.png}}{{#vardefine:icon-tooltip|Unrecognized icon name}}{{#vardefine:icon-size-word|normal}}{{#vardefine:icon-size|}}{{#vardefine:icon-image|Icon optional.png}}{{#vardefine:icon-tooltip|Optional}}{{#var:icon-tooltip}}[[{{#var:icon-link}}|​]]
content style

Specifies CSS styles to apply to the content area.

{{#vardefine:icon-highuse|}}{{#vardefine:icon-link|}}{{#vardefine:icon-image|Icon question.png}}{{#vardefine:icon-tooltip|Unrecognized icon name}}{{#vardefine:icon-size-word|normal}}{{#vardefine:icon-size|}}{{#vardefine:icon-image|Icon optional.png}}{{#vardefine:icon-tooltip|Optional}}{{#var:icon-tooltip}}[[{{#var:icon-link}}|​]]
footer style

Specifies CSS styles to apply to the footer area.

{{#vardefine:icon-highuse|}}{{#vardefine:icon-link|}}{{#vardefine:icon-image|Icon question.png}}{{#vardefine:icon-tooltip|Unrecognized icon name}}{{#vardefine:icon-size-word|normal}}{{#vardefine:icon-size|}}{{#vardefine:icon-image|Icon optional.png}}{{#vardefine:icon-tooltip|Optional}}{{#var:icon-tooltip}}[[{{#var:icon-link}}|​]]
header style

Specifies CSS styles to apply to the header area.

{{#vardefine:icon-highuse|}}{{#vardefine:icon-link|}}{{#vardefine:icon-image|Icon question.png}}{{#vardefine:icon-tooltip|Unrecognized icon name}}{{#vardefine:icon-size-word|normal}}{{#vardefine:icon-size|}}{{#vardefine:icon-image|Icon optional.png}}{{#vardefine:icon-tooltip|Optional}}{{#var:icon-tooltip}}[[{{#var:icon-link}}|​]]
image style

Specifies CSS styles to apply to the image area.

{{#vardefine:icon-highuse|}}{{#vardefine:icon-link|}}{{#vardefine:icon-image|Icon question.png}}{{#vardefine:icon-tooltip|Unrecognized icon name}}{{#vardefine:icon-size-word|normal}}{{#vardefine:icon-size|}}{{#vardefine:icon-image|Icon optional.png}}{{#vardefine:icon-tooltip|Optional}}{{#var:icon-tooltip}}[[{{#var:icon-link}}|​]]
style

Specifies CSS styles to apply to all areas.

Examples

No border, no image

{{Mbox
|header        =Example notice
|content       =Example notices serve example purposes.
|footer        =Example footer
|border        =none
}}

results in:

Example notice
Example notices serve example purposes.

Border, image, background color

{{Mbox
|header        =Example notice
|content       =Example notices serve example purposes.
|footer        =Example footer
|border        =#ABA000
|bg            =#DDDDDD
|image         =Mbox default.svg
}}

results in:

Example notice
Example notices serve example purposes.
Community content is available under CC-BY-SA unless otherwise noted.