Motorway Services Online

Retrieved from "https://motorwayservices.uk"

Template:Gallery

This template is used to create a more prominent link to the photo gallery pages, replacing a former link at the top. It can come with a promoted image, or do without it.

It should be used as follows:
{{Gallery
|image = A FILENAME (as an example photo)
|caption = A CAPTION FOR THAT PHOTO
|size = THE SIZE OF THAT PHOTO (in pixels, but without the "px") }}

Additional variables built in are 'name' for the page name, 'width' for the photo width, 'keydates' for use with Template:Key Date. These variables are all optional - you can have a gallery link with no image, or an image with no size or caption.

If the sample image being displayed here should also be the #setmainimage (the one image chosen to represent that page), you can set 'setmainimage' to 'yes'. Don't do this if the page already uses #setmainimage, or if the page has a template that uses it, like Template:Services and Template:Infobox.

Finally, if the gallery you are linking to has more than one name (for example "Swansea" is widely known as "Swansea West"), the count of how many photos are available will be wrong. To get around this, use the variable 'gallery' to add a second name. In this case, if you were linking to Gallery:Swansea West, you'd set "|gallery = Swansea" to make sure Swansea is included in the photo count too.

This template can generate either a photo gallery box, or a list of key dates.

Template parameters

This template prefers inline formatting of parameters.

ParameterDescriptionTypeStatus
Gallery Namename

The name of the gallery that you are linking to, without the 'Gallery' prefix.

Default
{{PAGENAME}}
Example
Keele
Page namesuggested
Additional Galleriesgallery

The box will count how many photos there are. If you want that count to include additional galleries (for example old page names), include them here. To add more than one gallery, separate each one with a ¦ and put the word 'pictures' on the end of each one, except the last

Example
Keele OR Locks Garage pictures¦Lock's Garage
Stringoptional
Sample Imageimage

A single image can be displayed in a large box.

Example
File:Keele.jpg
Filesuggested
Widthsize width

The width of the sample photo that will appear, in pixels, without the px

Default
200
Example
250
Unknownsuggested
Photo Captioncaption

A caption to go beneath the sample image.

Stringsuggested
Promote Sample Imagesetmainimage

Every page needs a 'main image' to represent it. If this is that image, set this to yes.

Default
false
Example
yes
Booleanoptional
Don't Promote Sample Imageduped

By default, the sample image you enter will become the 'main image' for that page. Only one image can be the main image, and other templates may be trying to suggest one, too. Use this box to declare that your image doesn't want to become the main image.

Default
false
Example
yes
Booleandeprecated
Key Dateskeydates

If you want to list key dates using the {{Key Date}} template, enter them here.

Example
{{Key Date | 2010 | Services opened }}
Contentoptional