Final Configuration for the Forum Permissions

Started by smilodon, February 09, 2009, 05:19:26 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

Whitey

Nice work gents! (and Pen) :D

I've started moving some of the posts I'd like to keep from the archived area into the new structure.

smilodon

Go for it. Frankly I'd like to get shot of Charlie and Bravo access completely. So if we can bring good stuff from their old forums back into the existing forum structure that would work best I think. That's true for any of the Bravo/Charlie stuff we want to keep.

Knock yourselves out.
smilodon
Whatever's gone wrong it's not my fault.

Gandalf

Quote from: smilodon;262991Go for it. Frankly I'd like to get shot of Charlie and Bravo access completely. So if we can bring good stuff from their old forums back into the existing forum structure that would work best I think. That's true for any of the Bravo/Charlie stuff we want to keep.

Knock yourselves out.

I agree. drop em :D Archive threads and kill dead groups.
*G*

Cake: Four large eggs. One cup semi-sweet chocolate chips. Three/four cups butter or margarine. One and two third cups granulated sugar. Two cups all purpose flour. Fish shaped ethyl benzene. Twelve medium geosynthetic membranes. Three tablespoons rhubarb, on fire.

Penfold

Just to confirm.......... Yes definitely - let's kill the access.

The Bravo and Charlie forums can stay in the Archive section. You never know when we may want to check back on something or indeed revisit some classics from the past.

Whitey, I know you're pretty good at this but give me a shout if you want help with anything moved back from archive. I feel all empowered now I know how to do it:)

hehe

smilodon

Quote from: Penfold;263032I feel all empowered now I know how to do it:)

hehe
The kiss of forum death :rolleyes:

I'll wait till the scripts are done and we can see everyone getting their new permissions. Then I'll revert everyone back to Registered Users as their primary user group. And then we can dump Charlie and Bravo.
smilodon
Whatever's gone wrong it's not my fault.

smilodon

Quote from: Gandalf;262955]As you can see, section heads and admins get assigned to the same usergroup. This is NOT set in stone and can be changed as required. EG: Section Head assigned to one group, Admins to another. Just tell me what needs to happen!

OK here goes. I think we have decided that we want to keep the four games separate with separate user groups for green and red game badge holders. As an example there is a need for a CS admin to be able to see and post into the CS admin forum but not have him or her see into the L4D admin forum.


1. Section Heads do not need a script. They are already in the Section Head user group and have almost complete access to the forum already.

2. Game admins (red badge holders). There are four game admin user groups, one for each game. The four red game badges need to be assigned to each of these games i.e. the red CS badge needs to link to the CS Game Admin user group. The same for CoD4, L4D, dMr and DMR. So I assume four scripts. There are admin forums that are for specific games and we've decided that CS admisn do not get access to L4D admin forums and so on.

3. Public Admins (no badges) these user groups have no badge associated with them and so need no script. I'll do them manually as only CS uses public admins at the moment.

4. Supporting members. I need a script to assign the supporting member badge holders to the supporting member user group.

5. General green badge holders. I need a script to assign all non game green badge holders LAN, folding and forum contributor) to the green badge holder user group. This will give them access to the green badge chat forum only.

5. Game green badge holders. I have a green badge holder user group for each of the four games. I need four scripts to add each green badge holder type to the relevant Green badge holder user group. So one for CS, CoD4, L4D, dMr and DMR. For example this is to allow the CS green badge holders access to their private CS forum but not allow the L4D access and so on. The CS and CoD4 trialists should be treated as green badge holders for their respective games i.e. CS Trialist has the same user group and a CS Green badge holder and the CoD4 trialist has the same suer group as the CoD4 Green badge holder.

6. The correct permissions are already set up for the WOW players. They have been assigning a guild member group (green badge) and a council member group (red badge) since they began. It would be nice to have a script system for them too as it will automate any future promitions etc and make all four games work in the same way.

Hope this makes sense? After three days I nearly get it :blink:
smilodon
Whatever's gone wrong it's not my fault.

Gandalf

As long as there is an award and relevant group then the script will work. It's all one script too, I just tell it what award belongs to what group and loop until complete.

WoW badge holders can be assigned by script too. Just need to be set like the other games.

So, does that list of awards and groups still stand? (bar WoW which needs adding)
*G*

Cake: Four large eggs. One cup semi-sweet chocolate chips. Three/four cups butter or margarine. One and two third cups granulated sugar. Two cups all purpose flour. Fish shaped ethyl benzene. Twelve medium geosynthetic membranes. Three tablespoons rhubarb, on fire.

smilodon

WOW are in my list from before. marked in red. Although the groups are up to date I'd still like them in the script for future updates. I've added two more requirements in green at the bottom.The idea being that when LAN helpers and 500,000+ folders get their red badges they loose the green ones. If that is so they would loose their permissions to the green badge holder chat when the script was next run. This is  assuming they did not hold another green badge as well, unlikely but possible.


  • ID 39 ->                                    id 52...............................L4D green badge holder
  • ID 31 ->                   id 40...............................WOW guild member (Green Badge Holder)

  • ID 17                                                   -> id 51...............................dMr Green Badge Holder
  • ID 13 ->                                  id 43...............................CS Green Badge Holder
  • ID 14 ->                                  id 43...............................CS Green Badge Holder
  • ID3 ->                    id 50..................................CoD4 Green Badge Holder
  • ID 6  ->                  id 50.................................CoD4 Green Badge Holder
  • ID 38 ->                 id 46...............................L4D Game Admin (L4D red badge)
  • ID 32 ->  id39.................................WOW Council member (Red badge Holder
  • ID18 ->                  id 37.................................dMr Game Admin (dMr red badge)
  • ID 12 ->                 id 23...............................CS Game Admin (CS red badge)
  • ID 5 ->                   id 38.................................CoD4 Game Admin (CoD4 red badge)
  • ID 29  ->                 id 48...............................Supporting Member
  • ID 9  ->                  id 53..................................General Green Badge Holder (fourm contributor
  • ID 25 ->                 id 53................................General Green Badge Holder (LAN attendee)
  • ID 21 ->                 id 53................................General Green Badge Holder (active Folder)
  • NEW ID 20 -> id 53.......................500,000+Folding (Red Badge Holder)
  • NEW ID 24 -> id 53.......................LAN helper (red LAN badge)
smilodon
Whatever's gone wrong it's not my fault.

Gandalf

ok, I'm going to start on the script and test on the test forum. As there are multiple variants it is going to require re-writing in places so may take a little longer than anticipated. Shouldn't be too troublesome though.
*G*

Cake: Four large eggs. One cup semi-sweet chocolate chips. Three/four cups butter or margarine. One and two third cups granulated sugar. Two cups all purpose flour. Fish shaped ethyl benzene. Twelve medium geosynthetic membranes. Three tablespoons rhubarb, on fire.

Penfold


smilodon

Just one though. The user groups are not mirrored on the test forum. I'm not a total wuss like Penfold so did the permissions on the live forum. Not sure if the fact that there are not all the same user groups will matter? I can make them on the test forum tonight if you want?
smilodon
Whatever's gone wrong it's not my fault.

Gandalf

ok, no probs, it should be ok. I'll just use some existing groups and awards. Shouldn't be a problem.
*G*

Cake: Four large eggs. One cup semi-sweet chocolate chips. Three/four cups butter or margarine. One and two third cups granulated sugar. Two cups all purpose flour. Fish shaped ethyl benzene. Twelve medium geosynthetic membranes. Three tablespoons rhubarb, on fire.

Gandalf

Right, all done. I've copied the groups from the existing forum to the test via a good old fasioned SQL dump so that was easy (and before you ask, no, I would not have done this on the live as it could have screwed up bad!)

Script in place that will now loop through the array of awards and grab all users and assign them to the associated group if not already assigned.

It will also check for users that are currently assigned to a group and checks that they do have the award assigned and if they don't then it will remove that user from the relevant group.

Now, this was part of the subscription to awards task but as this now takes around 3-5 seconds to run I've created a separate script and will assign it to it's own time.

Just so you know how the tasks run, they are called scheduled tasks but they do not run 'on the dot' they require someone to click any link in the forum to run as the software will check to see if there is a task to run and if so will run it. The downside to this is if the task is rather data intensive as this new one is, then the person clicking the link will get a slight delay.

The tasks do run at the end of the page load so it 'should' not be noticeable but I thought I'd mention it incase people start to say that the forum freezes every hour then recovers. If this becomes the case then we can set the task to run during the night and chances are a spider will fire off the task for us.

So if you'd like to check out the test forum you'll see people assigned to the relevant groups. NOTE: Permissions ARE NOT DONE! I only mirrored the groups.

Without doing a full backup of live and restore onto test I cannot test any further. But I'm happy that it won't hose anything!

Let me know when you'd like this placed on the live forum.
*G*

Cake: Four large eggs. One cup semi-sweet chocolate chips. Three/four cups butter or margarine. One and two third cups granulated sugar. Two cups all purpose flour. Fish shaped ethyl benzene. Twelve medium geosynthetic membranes. Three tablespoons rhubarb, on fire.

smilodon

I'll have a rummage about this evening. many thanks :D
smilodon
Whatever's gone wrong it's not my fault.

Gandalf

And here is the array that assigns users to the relevant group. The first value is the award, the second is the corresponding group. Any additions can be tacked onto this array, no extra coding required :)

// Groups
$grouparr = array(
3 => 50,
5 => 38,
6 => 50,
9 => 53,
12 => 23,
13 => 43,
14 => 43,
17 => 51,
18 => 37,
20 => 53,
21 => 53,
24 => 53,
25 => 53,
29 => 48,
31 => 40,
32 => 39,
38 => 46,
39 => 52
);
*G*

Cake: Four large eggs. One cup semi-sweet chocolate chips. Three/four cups butter or margarine. One and two third cups granulated sugar. Two cups all purpose flour. Fish shaped ethyl benzene. Twelve medium geosynthetic membranes. Three tablespoons rhubarb, on fire.