Jump to content
Main menu
Main menu
move to sidebar
hide
Navigation
Main page
Recent changes
Random page
Help about MediaWiki
Numinix MediaWiki Demo
Search
Search
Appearance
Create account
Log in
Personal tools
Create account
Log in
Pages for logged out editors
learn more
Contributions
Talk
Editing
Manual/User rights
(section)
Page
Discussion
English
Read
Edit
View history
Tools
Tools
move to sidebar
hide
Actions
Read
Edit
View history
General
What links here
Related changes
Special pages
Page information
Appearance
move to sidebar
hide
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
=== Adding new rights === <!--T:175--> </translate> ''<translate><!--T:176--> Information for coders only follows.</translate>'' <translate><!--T:177--> If you're adding a new right in core, for instance to [[<tvar name=2>Special:MyLanguage/Manual:Special pages</tvar>|control a new special page]], you are ''required'' to add it to the list of available rights in <tvar name=User></tvar>, <tvar name=1></tvar> ([<tvar name=url>https://gerrit.wikimedia.org/r/c/mediawiki/core/+/559622/9/includes/Permissions/PermissionManager.php</tvar> example]).</translate> <translate><!--T:178--> If you're , you instead need to use <tvar name=2></tvar>, or preferably define the right in <tvar name=3></tvar>.</translate> <translate> <!--T:179--> You probably also want to assign it to some user group by editing <tvar name=GroupPermissions></tvar> described above. <!--T:217--> If you want this right to be accessible to external applications by <tvar name=OAuth></tvar> or by [[<tvar name=1>Special:MyLanguage/Manual:Bot passwords</tvar>|bot passwords]], then you will need to add it to a grant by editing <tvar name=GrantPermissions></tvar>. </translate> <syntaxhighlight lang="php" copy> // <translate nowrap><!--T:231--> create projectmember-powers right</translate> $wgAvailableRights[] = 'projectmember-powers'; // <translate nowrap><!--T:232--> add projectmember-powers to the projectmember-group</translate> $wgGroupPermissions['projectmember']['projectmember-powers'] = true; // <translate nowrap><!--T:233--> add projectmember-powers to the 'basic' grant so we can use our projectmember powers over an API request</translate> $wgGrantPermissions['basic']['projectmember-powers'] = true; </syntaxhighlight> <translate><!--T:180--> You also need to add and interface messages to <tvar name=3>languages/i18n/en.json</tvar> (with documentation in <tvar name=4>qqq.json</tvar>).</translate> <translate><!--T:181--> The <tvar name=1><code>right-*</code></tvar> messages can be seen on <tvar name=2>[[Special:ListGroupRights]]</tvar> and the <tvar name=3><code>action-*</code></tvar> messages are used in a sentence like "You do not have permission to ...".</translate> <translate>
Summary:
Please note that all contributions to Numinix MediaWiki Demo may be edited, altered, or removed by other contributors. If you do not want your writing to be edited mercilessly, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource (see
Project:Copyrights
for details).
Do not submit copyrighted work without permission!
Cancel
Editing help
(opens in new window)