From MediaWiki.org
Jump to navigation Jump to search
MediaWiki extensions manual
OOjs UI icon advanced.svg
Custom Tabs
Release status: stable
Implementation Mywiki, Skin
Description Allows for fully configurable content actions (tabs)
Author(s) Ryan Schmidt (Skizzerztalk)
Latest version 1.1
MediaWiki 1.12+
License GPL
Download Download
Translate the GroupPermissionsManager extension if it is available at translatewiki.net

This plugin hides tabs for certain users. It also allows the creation of custom tabs by an interface message.


This plugin needs the ExtendedPermissions core plugin to work properly.

If a user is unable to read a page or execute an action, that tab will be automatically hidden. As of right now, the variable $wgGPManagerShowEditTab can be set to true so that the edit tab is always shown even if the user isn't allowed to view page source.

Default tabs shown[edit]

The MediaWiki:Content actions message controls what tabs appear and what order they appear in. The default looks something like this:


All of the above are "magic words" that automatically create one of the default tabs. If the user normally would not be able to see that tab, it won't be shown. It is recommended that you leave all of the above in the message.

New tabs[edit]

New tabs can be defined in the format * tab-url | tab-name | permission. The URL and name are required, and the permission is optional. Any wiki markup besides the opening bullet point is not allowed.

  • tab-url: the URL that the tab will be pointing to, may be one of the following (will be checked in the following order as well):
    • The name of a MediaWiki message
    • An internal page
    • A URL pointing to somewhere offsite
  • tab-name: the name of the tab that will appear (and is also the ID of the tab for CSS stylings). Can be one of the following (again parsed in order):
    • The name of a MediaWiki message
    • Plain text
  • permission: the permission required in order to be able to see the tab. This is optional, and if excluded, the ability to read the wiki will be checked.

An example of a few custom tabs follows.

* mainpage | mainpage-text
* MediaWiki | The Main Page
* http://www.google.com | google
* Special:BlockIP | block someone! | block

MediaWiki:Mainpage and MediaWiki:Mainpage-text both exist, and MediaWiki is a page on this wiki. MediaWiki:Google does not exist.

This would produce four custom tabs. The first tab links to the main page of this wiki, since the contents of MediaWiki:Mainpage lead there. The contents of MediaWiki:Mainpage-text are displayed on the tab. The second one also links to the main page of this wiki, but is not a system message. The literal text "The Main Page" is shown on the tab. The third tab links to Google and has a literal "google" on the tab. The fourth tab links to Special:BlockIP with the literal text "block someone!", but only shows up for people who have the ability to block (sysops).

Download instructions[edit]

This plugin is a core plugin and as such is packaged with the extension. Please follow these directions to download either the full extension or just this plugin.


To install this plugin, place the .php file inside of the /plugins sub-directory of your GroupPermissionsManager extension. Then, browse to Special:Version of your wiki to confirm that "CustomTabs" appears in there.

See also[edit]