Page MenuHomeMiraheze

How can I edit $wgRestrictionLevels ?
Closed, ResolvedPublic

Description

Wiki URL321nails.crpteam.club

I'm a little confused that I can't find a place where I can change $wgRestrictionLevels. I need this to add a new protection level in order to make my wiki more similar to Wikipedia.

So is it possible to change $wgRestrictionLevels? Also, is it possible to add an option to ManageWiki to change this? thanks.

Event Timeline

Herald added subscribers: Unknown Object (User), Unknown Object (User), Reception123. · View Herald TranscriptAug 5 2022, 08:43

Also, what I need to add is:

$wgRestrictionLevels[] = 'templateeditor'; 
$wgRestrictionLevels[] = 'extendedconfirmed';
In T9629#194460, @Ugochimobi wrote:

@Creeper19472 what exactly do you want to set?

That is.

So let's say you need the templateeditor and extendedconfirmed user groups in your wiki, right?

Yes, that's right. But I think I can create these two user groups myself. Of course, it would be better if you could create permissions and user groups with the same name.

Yeah, I will make a PR to make the permissions available on your wiki, so that you can create the groups via ManageWiki.

Unknown Object (User) added a comment.Aug 5 2022, 09:10
In T9629#194465, @Ugochimobi wrote:

Yeah, I will make a PR to make the permissions available on your wiki, so that you can create the groups via ManageWiki.

Groups need to be created first I think, and than new permissions added, that can then be given to the groups in ManageWiki.

And restriction levels needs done in LocalSettings.php, because ManageWiki does not support it, but might eventually (T9195)

In T9629#194465, @Ugochimobi wrote:

Yeah, I will make a PR to make the permissions available on your wiki, so that you can create the groups via ManageWiki.

Groups need to be created first I think, and than new permissions added, that can then be given to the groups in ManageWiki.

And restriction levels needs done in LocalSettings.php, because ManageWiki does not support it, but might eventually (T9195)

Err... I don't think this affects it. Permissions and user groups exist independently.
Of course, to grant permissions I have to add user groups first.

Unknown Object (User) added a comment.Aug 5 2022, 09:19

Of course, to grant permissions I have to add user groups first.

Yes, that is what I meant. Sorry for wording that confusingly.

Unknown Object (User) added a comment.Aug 5 2022, 09:22
In T9629#194474, @Ugochimobi wrote:

PR: https://github.com/miraheze/mw-config/pull/4847
It will be ready when this PR is merged

I will review and merge that in a few minutes hopefully.

Unknown Object (User) closed this task as Resolved.Aug 5 2022, 09:23
Unknown Object (User) assigned this task to Excelsis.

Merged.

Sorry, but there's another problem.
I do not see any changes on my site. Is it because I need time for synchronization or other operations or because I need to clear the cache locally?

Did you try creating the user groups?
Go to;

  • Special:ManageWiki/permissions, on the Create new user group option insert the name of the group (templateeditor for Template editors and extendedconfirmed for Extended confirmed users)
  • For extendedconfirmed group, On the next page go to the Unassigned Permissions tab and look for editextendedconfirmedprotected and click the check box beside it and SAVE. (you can use your browser's search feature to look for it by pressing CTL+F then enter editextendedconfirmedprotected in the search bar.
  • For templateeditorgroup, On the next page go to the Unassigned Permissions tab and look for edittemplateprotected and click the check box beside it and SAVE. Follow the same procedures above.

For an extra note, since you want your extendedconfirmed group to look like Wikipedia's, then on extendedconfirmed you might want to go the the Autopromotion tab and set the number of days and edits the user account needs to be/have, before they're promoted to the group automatically.

I just hope you understand my jargon above :)

Err... In fact, I just still haven't found these two permissions. Search yielded no results. User groups have been created, and it is not seen in the permission settings of the user group.

Well... actually, there are still some problems.
I can see these two new permissions now, but still can't set the protection level like this in the protection list - it seems that they are not added to the list of options available.

It makes no sense. I can't figure out where the problem is. :(

Sorry. It's my fault. I forget to add permissions to the sysop groups... So yeah, I can't use them, of course.