Template:Gallery

From KeyToNature
Jump to: navigation, search
[edit] [purge] Template-info.svg Template documentation

This gallery template shows up to 100 images. The big advantage over the build-in gallery tag (<gallery>...</gallery>) is that the available space will be dynamically used, depending on available screen space. Furthermore, the captions may contain template calls (which is not possible with the build-in tag).

Every image is embedded in its own HTML-table, and are floated left. The number of images per row is based upon the width specified and the width of the screen, which allows greater flexibility than the build-in <gallery> tag.

Example

{{Gallery
 | title=Title of gallery goes here
 | footer=*Image credit: Wikipedia commons, the free encyclopedia<br />**and so on...
 | width=150
 | lines=2
 | File:Information_icon.svg|this is a caption
 | File:Information_icon.svg|
 | File:Information_icon.svg|
 | File:Information_icon.svg|
 | File:Information_icon.svg|
 | File:Information_icon.svg|
 | File:Information_icon.svg|
 | File:Information_icon.svg|
 | File:Information_icon.svg|[[Help:Contents/Links|Links]] can be put in captions.
 | File:Information_icon.svg|
 | File:Information_icon.svg|
 | File:Information_icon.svg|
 | File:Information_icon.svg|Full [[MediaWiki]]<br />[[syntax]] may now be used…
 | File:Information_icon.svg|
 }}

results in:

Title of gallery goes here
this is a caption
this is a caption  
Information icon.svg
 
Information icon.svg
 
Information icon.svg
 
Information icon.svg
 
Information icon.svg
 
Information icon.svg
 
Information icon.svg
 
Links can be put in captions.
Links can be put in captions.  
Information icon.svg
 
Information icon.svg
 
Information icon.svg
 
Full MediaWikisyntax may now be used…
Full MediaWiki
syntax may now be used…  
Information icon.svg
 
*Image credit: Wikipedia commons, the free encyclopedia
**and so on...

See English Wikipedia: Gallery template for detailed information.