Template:Version: Difference between revisions

From Against the Storm Official Wiki
m (added example of when a page is up to date.)
(Updating to match the updated module; just a parameter name change for clarity)
 
(4 intermediate revisions by the same user not shown)
Line 1: Line 1:
<includeonly>{{#invoke:VersionMessageBox|checkVersion|updated={{{1|{{{updated|}}} }}}|currentVersion={{CurrentVersion}} }}</includeonly><noinclude>
<includeonly>{{#invoke:VersionMessageBox|main
|lastupdated={{{1|{{{lastupdated|}}} }}}
|currentversion={{CurrentVersion}}
}}</includeonly><noinclude>


<code><nowiki>{{#invoke:VersionMessageBox|checkVersion|updated={{{1|{{{updated|}}} }}}|currentVersion={{CurrentVersion}} }}</nowiki></code>
{{Documentation}}
 
This template references <code><nowiki>{{CurrentVersion}}</nowiki></code>, which is currently {{CurrentVersion}}.
 
Place this template at the top of every page.
 
== Example ==
 
{{Version|0.39.2}}
 
Then when the page text follows the call to the template, the version message box will appear nicely above the text.
 
But when you make a page up to date with the current version of the game, and you write the current version of the game in the argument, there will be no message box.
 
{{Version|{{CurrentVersion}} }}
 
There's a call to the template above this line.


</noinclude>
</noinclude>

Latest revision as of 18:00, 15 October 2024


This is the Template Documentation from Template:Version/doc.

Overview

Place this template at the top of every page that has any user-generated content. Pages with only dynamically updated data, like infoboxes and recipe tables do not need this template at the top until authors have added content by hand.

Creates a message box that displays when the page content is out of date. This template references Template:CurrentVersion, which is currently 1.4.17. If that's not correct, please go update it!

Parameters

Version

Specify the version number of the game as of your update.

Parameter Type Description
unnamed parameter string The version of the game as of your update. If the developers have labeled the version with a letter, for example, 1.0.2R, omit the letter: 1.0.2.

Examples

Basic usage

When the template call is included at the top of the article, the version message box will appear nicely above the rest of the page text.

{{Version|0.39.2}}

This article was last updated during version 0.39.2. The game is now in 1.4.17. Some information may be out of date. Help us keep the wiki up to date by comparing this article against the patch notes and updating it.

Other examples

When all of the content in an article is up-to-date, and you update the template call with the version as of today, the message box disappears.

{{Version|1.4.17}}


Since this template call uses the current game version, the information box does not appear.