Open main menu

For use on Image pages to show the image with a different background.

  • {{Background|<image name>|<size>|<color>|<caption>}}
  • {{Background|<image name>|<size>|<caption>|<color>}}
  • {{Background|[[File:<image name>|<size>|background=<color>|<caption>]]}}
  • {{Background|[[File:<image name>|<size>|bgcolor=<color>|<caption>]]}}
  • {{Background|[[File:<image name>|<size>|bg=<color>|<caption>]]}}
  • {{Background|[[File:<image name>|<size>|<color>|<caption>]]}}
  • {{Background|[[File:<image name>|<size>|<caption>]]|background=<color>}}
  • {{Background|[[File:<image name>|<size>|<caption>]]|bgcolor=<color>}}
  • {{Background|[[File:<image name>|<size>|<caption>]]|bg=<color>}}
  • {{Background|[[File:<image name>|<size>|<caption>]]|<color>}}

Using either one of them is fine, all deliver identical results.

  • width defaults to the full width of the image (just like [[File:.. does) and
    background color defaults to #E0E0E0 (i.e. the default for location maps).
  • {{Background|Cercle blanc 100%.svg|black|white circle}} gives the upper result to the right, demonstrating width default value
  • {{Background|Cercle blanc 100%.svg|thumb}} results in the lower view to the right, using background color default value

Wrapped Syntax Example

You can also just wrap a usual Image Definition like shown above to achieve the same effects:

  • {{Background|[[File:Cercle blanc 100%.svg|120px|thumb|left|white circle on green ground|green]]}}
  • {{Background|Cercle blanc 100%.svg|120px|thumb|left|white circle on green ground|green}}

deliver the same results. Using the same caption as the color spec is possible by simply passing it twice:

  • {{Background|[[File:Cercle blanc 100%.svg|120px|thumb|right|pink|pink]]}}

Further examples

Care was taken to allow wikilinks in the caption to a thumb:

  • {{Background|Cercle blanc 100%.svg|#0000ff|120px|thumb|[[:File:Cercle blanc 100%.svg]]}}
  • {{Background|Cercle blanc 100%.svg|120px|red|thumb|left|white circle}}

Note: Currently a caveat left is support of setting the background for Images embedded using the <imagemap> extension; naturally it has the same stock limitation like File/Image does..

See alsoEdit