Manual talk:$wgRestrictionLevels
Add topicTutorial
[edit]There is a nice tutorial about this configuration parameter. Enjoy. Cheers --[[kgh]] (talk) 21:31, 13 January 2013 (UTC)
- Kghbln: broken link by now, if you can fix it... Plyd (talk) 16:45, 18 May 2018 (UTC)
- here we are Cheers --[[kgh]] (talk) 16:48, 18 May 2018 (UTC)
Help
[edit]Hi, just wondering if someone can help me!
I'm running the trunk version of mediawiki, and I attempted to add this variable.
The wiki works fine, so I know nothing is wrong, but when I try to protect a page, the new options do not show up. Any ideas?
The code I am using is:
$wgRestrictionLevels = array ( '', 'autoconfirmed', 'sysop', 'staff', 'developer'); $wgRestrictionTypes = array( 'edit', 'move');
I have created the "staff" and "developer" MediaWiki: Pages, and both userrgroups are on my wiki. I am also a member of both.
Also, a space has appeared below the existing levels, that is presumably for the new levels - there is just no text.
Thanks,
Bluegoblin7 09:52, 18 August 2008 (UTC)
- You need to add the correct MediaWiki: messages as well. The messages you need are "MediaWiki:Protect-level-groupname" and "MediaWiki:Restriction-level-groupname", replacing both instances of "groupname" with the name of the group. The first is the text displayed on the protection form, and the latter is displayed in Special:ProtectedPages. --Skizzerz 14:41, 18 August 2008 (UTC)
- I had done that already. It says that ^.
- I'm going to rewrite the page i think, its misleading
- Bluegoblin7 14:53, 18 August 2008 (UTC)
sysop
[edit]I think it would be useful to add a note about the default value "sysop". As the description says, the values should be permissions, not group names. However, "sysop" is no permission, but a only a group name, so it makes people think group names were allowed. I wondered why it works for "sysop", but not for e.g. "bureaucrat". Looking at the source code, I found out that "sysop" is rewritten to "protect" for "Backwards compatibility". I checked this by setting the protection to "move=sysop" and then removing the "protect" permission from the sysop group. Indeed I could no longer move the page. So if you restrict a page to be edited/moved only by sysops, anyone with the "protect" permission will be able to edit/move it (which makes sense, they could as well unprotect the page if they wanted to). This underlines that you can't use group names, except for "sysop". --Robb1989 15:38, 18 April 2009 (UTC)
Multiple Protection Levels
[edit]Hello
I know the basics of using $wgRestrictionLevels and $wgGroupPermissions to create multiple protection levels, but getting exactly what I'm after is a bit tricky.
I want three protection levels, one for each of my user groups:
- Moderators
- Can be edited by Moderators, Administrators and Bureaucrats
- Only Bureaucrats can apply this level of protection
- Administrators
- Can be edited only by Administrators and Bureaucrats
- Both Administrators and Bureaucrats can apply this level of protection
- Bureaucrats
- Can be applied and edited only by Bureaucrats
The trouble that I'm having is with the Moderator level, as giving Administrators the right to "protect" pages automatically gives them the right to protect all levels that they can edit - I can't find a way to allow them to edit the Moderators level without being able to apply it.
So, if what I'm asking for is possible, could you please provide me with the code to set this up (all of it, I would rather be safe and be given all of the code, than just ask for the part about the Moderators level and assume I can work the rest around it).
MediaWiki version: 1.16.0
Thanks!
See the original post
Multiple Protection LevelsTalk 05:21, 15 November 2010 (UTC)