• Home
  • Random
  • Nearby
  • Log in
  • Settings
Donate Now If Wikipedia is useful to you, please give today.
  • About Wikipedia
  • Disclaimers
Wikipedia

Template:Highest archive number/sandbox

  • Template
  • Talk
  • Language
  • Watch
  • Edit
< Template:Highest archive number
This is the template sandbox page for Template:Highest archive number (diff).
Template documentation[view] [edit] [history] [purge]
This template uses Lua:
  • Module:Highest archive number (sandbox)

This template finds the highest archive number for a given set of archive pages.

Contents

  • 1 Usage
  • 2 Prefix syntax
  • 3 Archive number limitations
  • 4 Examples

Usage

edit
{{highest archive number|prefix|start=start number}}
  • prefix - the prefix of the set of archive pages. For example, for Talk:France/Archive 1, Talk:France/Archive 2, etc., the prefix would be "Talk:France/Archive ". For this parameter, whitespace must be input correctly for the template to work.
  • start - if the archive numbers do not start at 1, you must specify the starting number here. For example, the first archive for Wikipedia talk:WikiProject Chemicals is Wikipedia talk:WikiProject Chemicals/Archive 2005, so to find the highest archive number you would need to specify |start=2005.

Prefix syntax

edit

When specifying the archive prefix, you need to use the exact whitespace. For example, the following does not work, as there is a new line after the prefix:

{{highest archive number
|prefix
}}

In addition, if your prefix contains any equals signs ("="), you will need to replace them with the code {{=}}, otherwise everything in front of the first equals sign will be interpreted as a parameter name.

Archive number limitations

edit

The module this template is based on uses an exponential search algorithm to find the highest archive number. Due to the way this algorithm works, there cannot be any gaps in the archive numbers. For example, if archives 1, 2, 3 and 5 exist, but not archive 4, then the algorithm makes no guarantees about whether the highest archive number will be 3 or 5.

Examples

edit
  • {{highest archive number|Wikipedia:Administrators' noticeboard/IncidentArchive}} → 1198
  • {{highest archive number|Talk:Byzantine Empire/Archive }} → 18
  • {{highest archive number|Wikipedia talk:WikiProject Chemicals/Archive |start=2005}} → 2025
The above documentation is transcluded from Template:Highest archive number/doc. (edit | history)
Editors can experiment in this template's sandbox (edit | diff) and testcases (create) pages.
Add categories to the /doc subpage. Subpages of this template.
Retrieved from "https://en.wikipedia.org/w/index.php?title=Template:Highest_archive_number/sandbox&oldid=919746631"
Last edited on 5 October 2019, at 14:47

Languages

      This page is not available in other languages.

      Wikipedia
      • Wikimedia Foundation
      • Powered by MediaWiki
      • This page was last edited on 5 October 2019, at 14:47 (UTC).
      • Content is available under CC BY-SA 4.0 unless otherwise noted.
      • Privacy policy
      • About Wikipedia
      • Disclaimers
      • Contact Wikipedia
      • Code of Conduct
      • Developers
      • Statistics
      • Cookie statement
      • Terms of Use
      • Desktop