Version: 1.00, by TECK
Developer Last Online: Nov 2023
Version: 2.2.x
Rating:
Released: 07-06-2002
Last Update: Never
Installs: 36
No support by the author.
This hack will let you NOT allow certain users to edit your administrator usernames properties and also other options you want to restrict access to, for example editing the templates.
I recommend you to enable only the ones you really trust, that means only yourself.
[high]UPDATE[/high]
The hack was updated. It was fixed the problem I had with editing yourself of all users.
NOTE: FireFly posted also another way of doing this, few posts below.
In my hack, I also explained how to stop other admins to edit other options, for example the templates.
You like this hack? Please click on the [high]Install[/high] button.
To download the latest version of this hack, click below:
Show Your Support
This modification may not be copied, reproduced or published elsewhere without author's permission.
chen, i did this:
i created 2 admins, userid 1 and 2.
i created 1 registered user, userid 3.
now, userid 1 can edit all users and userid 2 can edit all users except the ones listed in $caneditadmin.
i tested all and it works perfectly, in my test board, with the code above. you try it and let me know please. thanks.
if ($HTTP_POST_VARS['action']=="doupdate") {
if (!in_array($bbuserinfo['userid'],array($caneditadmin)) and in_array($userid,array($caneditadmin))) {
echo "<p>You are not allowed to edit this user</p>";
exit;
}
let suppose you have 4admins in your board. if you use only userid 1 and 2 the others will not be able to edit ONLY the admins.
Let's say you have 4 admins, users A, B, C and D.
You add users A and B to $caneditadmin (Which will not work, but let's assume it does).
Users A and B will be able to edit any users.
Users C and D will be able to edit all users except users A and B.
But user C will still be able to edit user D, and vice versa.
That's how it works, right. But that's not how it's supposed to work, because users C and D can still edit other admins (i.e D and C, respectively).
Quote:
Originally posted by Nakkid This hack will let you allow ONLY certain users to edit your administrator usernames properties
This quote says the hack stops others from editing other admins... and that's not how it works.
If you have 10 admins and add one of them to $caneditadmin, the rest of the 9 won't be able to edit the first user, but will be able to edit one another.
i understand now chen. sorry, my 'romanian' english.
i dont care if thay can edit other admins. what i dont want is to be able to edit my options (userid 1 or others listed in $caneditadmin)...
you are missing the mysql part on the line..
it should read it:
admin/db_mysql.php and NOT admin/db_.php
when you hacked your forum with another hack, you made a mistake somewhere.