Previous Thread
Next Thread
Print Thread
Rate Thread
#103557 02/23/2002 9:57 PM
Joined: May 2001
Posts: 6
Junior Member
Junior Member
Offline
Joined: May 2001
Posts: 6
Grant moderators access to certain member functions on a version 6.04 board?

Basically, I would like to give mods the abilties to silence users (toggle "able to post notes"), ban ips, and remove anything offensive from member profiles. I would give mods access to the whole page, but I don't want them to be able to delete users or grant/revoke admin privilidges.

I'd make the people admins, but frankly I don't trust them with that much power. One would likely try to do something to one of the other admins or mess with the configuration settings.

Any help would be appreciated.

Sponsored Links
#103558 04/08/2002 2:22 AM
Joined: Sep 2001
Posts: 379
Member
Member
Offline
Joined: Sep 2001
Posts: 379
That is fairly simple and easy to do (couple of minutes will do). smile

First to let your moderators view/update the ban lists:

Open "cp.cgi" (in /cgi-bin)

Find:
###################
if (($ubb eq 'ban_lists') && ($status eq 'Administrator')) {
###################

Replace with:
###################
if ($ubb eq 'ban_lists'){
###################

Find:
###################
if (($ubb eq 'update_bans') && ($status eq 'Administrator')) {
###################

Replace with:
###################
if ($ubb eq 'update_bans') {
###################

Save and close "cp.cgi" (remember to keep backups!).

Open "cp_common.pl" (in /noncgi/Templates).

Find:
###################
if (userStatus == "Administrator") {
document.writeln("");
document.writeln("");
document.writeln("");
}
###################

Replace with:
###################
if (userStatus == "Administrator") {
document.writeln("");
document.writeln("");
document.writeln("");
}
if (userStatus == "Moderator") {
document.writeln("");
}
###################

Save and close "cp_common.pl".
Now your moderators will be able to view and modify the ban lists.

As for letting moderators view and modify member accounts, but not delete or make people admins...
that will take some "major" editing, more than I can write down at the moment. :rolleyes:

#103559 04/08/2002 2:29 AM
Joined: Mar 2002
Posts: 45
Member
Member
Offline
Joined: Mar 2002
Posts: 45
oh.

#103560 04/08/2002 3:29 AM
Joined: Sep 2001
Posts: 379
Member
Member
Offline
Joined: Sep 2001
Posts: 379
Not at all!

If you look at the changes in the cp_common.pl,
you'll see that the user must be a moderator OR an administrator to view/edit the ban lists.

It's the exact same format as is used for all the other control panel features.

The user access to the Control Panel pages is controlled in cp_common.pl, too. wink

Edit: Have a look at these two lines:

if (userStatus == "Administrator") {
if (userStatus == "Moderator") {


If the user is an Administrator or Moderator, he can go on, else not.

Of course you can do it like this instead:

if (($ubb eq 'update_bans') && ($status eq 'Administrator' || 'Moderator')) {

But I'll stick to the same format as used for some other functions in the control panel.


Link Copied to Clipboard
Donate Today!
Donate via PayPal

Donate to UBBDev today to help aid in Operational, Server and Script Maintenance, and Development costs.

Please also see our parent organization VNC Web Services if you're in the need of a new UBB.threads Install or Upgrade, Site/Server Migrations, or Security and Coding Services.
Recommended Hosts
We have personally worked with and recommend the following Web Hosts:
Shock Hosting
Stable Host
bluehost
InterServer
Visit us on Facebook
Member Spotlight
JAISP
JAISP
PA
Posts: 449
Joined: February 2008
Forum Statistics
Forums63
Topics37,583
Posts293,955
Members13,824
Most Online151,614
Nov 14th, 2025
Today's Statistics
Currently Online 2338
Topics Created 0
Posts Made 0
Users Online 0
Birthdays 27
Top Posters
AllenAyres 21,080
JoshPet 10,369
LK 7,394
Lord Dexter 6,708
Gizmo 5,834
Greg Hard 4,625
Top Posters(30 Days)
Top Likes Received
isaac 82
Gizmo 20
Brett 7
WebGuy 2
Morgan 2
Top Likes Received (30 Days)
None yet
The UBB.Developers Network (UBB.Dev/Threads.Dev) is ©2000-2026 VNC Web Services

 
Powered by UBB.threads™ PHP Forum Software 8.1.0
(Snapshot build 20260108)