MyBB Community Forums

Full Version: [Beta]Control ModCP
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2
May peace be upon you.
This plugin controls the what moderators/super moderators can edit in the profile editor. i.e. it adds no new feature. It only allows better control.
This plugin needs to be tested.

Feel free to add new features to this plugin and post it here.
Regards

Download removed until next re-write in November
Ooohh nice! Thanks for sharing. Smile
I'm going to download it. Smile
This plugin is incompatible with MyBB 1413 error.
(2010-05-02, 03:37 PM)Mc Hammer Wrote: [ -> ]This plugin is incompatible with MyBB 1413 error.

Open the plugin with a text editor.
Find this line:
"compatibility" => "16*"
Replace with:
"compatibility" => "14*"
Else, re-download the file from the first post.




(2010-05-02, 10:50 AM)Rozzy Wrote: [ -> ]Ooohh nice! Thanks for sharing. Smile

(2010-05-02, 02:00 PM)darkly Wrote: [ -> ]I'm going to download it. Smile
Smile
(2010-05-02, 04:48 PM)Nayar Wrote: [ -> ]
(2010-05-02, 03:37 PM)Mc Hammer Wrote: [ -> ]This plugin is incompatible with MyBB 1413 error.

Open the plugin with a text editor.
Find this line:
"compatibility" => "16*"
Replace with:
"compatibility" => "14*"
Else, re-download the file from the first post.




(2010-05-02, 10:50 AM)Rozzy Wrote: [ -> ]Ooohh nice! Thanks for sharing. Smile

(2010-05-02, 02:00 PM)darkly Wrote: [ -> ]I'm going to download it. Smile
Smile

Thank you.
Very nice plugin, can't believe this isn't core.
(2010-05-03, 06:26 PM)41shots Wrote: [ -> ]Very nice plugin, can't believe this isn't core.
Thanks Smile
I fought a lot for this feature but then decided to learn php and do it myself.
Lets hope it will be core in the future
Thank you Nayar
you did good worck it work for me profectly
yhank you
Nayar - I have a few issues with your plugin...

	$user = get_user($mybb->input['uid']);

Although this does get checked in the function, you should perform some sort of validation to ensure you actually have a user to edit and show an error if there isn't.

Also, the entire modcpperm function runs whether you're editing a profile or not. In this function, you could do this:

if($mybb->input['action'] != "editprofile")
{
	return false;
}

...and just another gripe, but correct me if I'm wrong - these settings seem global? As in if you set an option to 'no', then no moderator can edit that section. This includes administrators and all moderators? I'm not too sure if you planned to do that or not...

Last thing, there are 11 str_replace function calls. This function accepts arrays as parameters, so it would be a lot easier if you added the strings and replacements then only one str_replace function is needed...
Pages: 1 2