Namespaces
Variants
Actions

Template:RandomSelector

Jump to: navigation, search

This template returns a "random" item from the set specified in as parameters.

The "random" number is based on the date/time in seconds + an offset. The default update by seconds means that the selected options are updated every page refresh - you can change the seed to a different time using the "seed" parameter. The offset allows you to use the random selector at multiple points in the page and get different results (just add a new number for each instance)

Internal use only.

This template is used by Template:RandomWikiHomeCategory.

Usage

{{RandomSelector|offset=a number|item1|...|itemN}}

The parameters are:

  • offset: (optional) Offset to current seed. Allows a different "random" selection if selector used more than once on a page. Usually just update number by one for every instance of the template on the page
  • seed: (optional) completely changes the seed. By default the seed is the time (in seconds) which implies an update every time page is refreshed.
  • Un named parameters: up to 12 parameters

Appearance

The default template does not have an appearance

{{{1}}}

 
Nokia Developer aims to help you create apps and publish them so you can connect with users around the world.

京ICP备05048969号  © Copyright Nokia 2013 All rights reserved