Extension:UrlGetParameters

This extension enables you to use and/or display the "GET" parameters of the URL, i.e. the query string, on the wiki page.

Installation

 * 1) Copy the code from below into a file called UrlGetParameters.php.
 * 2) Drop this script in $IP/extensions/UrlGetParameters
 * Note: $IP is your MediaWiki install dir.
 * 1) Enable the extension by adding this line to your LocalSettings.php: require_once('extensions/UrlGetParameters/UrlGetParameters.php');

Usage
To display the value of a URL get parameter in your page, you might do this: Where parameter-name is the name of the parameter whose value you want. If the parameter is not found, the extension will result in nothing. Alternatively, you can also specify a default value as follows: When the parameter parameter-name is not available, then the value default-value is returned.

If the URL contains parameters of the form "A[B]=C", you can display the value "C" in a similar way, by calling:

Authors
This extension was written by S.O.E. Ansems. Important contributions were made by Ankit Garg and some anonymous editors.

Version history

 * 1.0 - February 21, 2008 - initial version
 * 1.1 - February 15, 2008 - page caching disabled; handling added for array parameters; security fix added using rawurlencode