Template:?

From Angelina Jordan Wiki


Documentation

This template forms a query string for use in a URL, including the leading ? character. The almost identical {{qs}} doesn't include the ?.

At the moment this is very basic, simply chaining together input with no additional processing. (In particular, nothing is URL-encoded. If you need that, you'll have to do it yourself inside the template call. Although this may be added here as an option sometime in the future.)

Usage

  • {{?|name1|value1|name2|value2|}}

Up to 10 name/value pairs can be specified. If you need more for some reason, you can tack on a call to {{qs}} after a & character (see the last example below).

Examples

  • {{?}} ⇒ ?
  • {{?|}} ⇒ ?
  • {{?|v|nwFloCPXzCs}} ⇒ ?v=nwFloCPXzCs
  • {{?|set|a.1330448190421804|type|3}} ⇒ ?set=a.1330448190421804&type=3
  • {{?|a|1|b|2|…j|10}}&{{qs|k|11|l|12}} ⇒ ?a=1&b=2&…j=10&k=11&l=12

Alias

  • {{make-query}}

See also

  • {{qs}} – a near-alias of this template, except it doesn't output the leading question mark: {{qs|v|nwFloCPXzCs}} ⇒ v=nwFloCPXzCs