Log in


  • Category: Uncategorized
  • License: GNU General Public License (GPL) version 2
  • Updated: 2012-2-21
  • Downloads: 1458
  • Recommendations: 6


Previous releases:

Other Projects

View Arck Interactive's plugins

Group Administrators for Roles for Elgg 1.8

Implements the Group Administrator role via the Roles framework

Last updated 788 days ago

This plugin adds more granular access to your site by introducing a new user role: Group Administrator.

When using this plugin, regular members of your site won't be able to create groups. A user has to be a Group Administrator to create a new group. To appoint one of your users as a Group Administrator, change this user's role to 'Group Administrator'. You can do this by going to the user's settings page, which is something like http://your-site-url/settings/user/username . Alternatively, you can also grant and revoke Group Admin privileges via the user icon hover menu. Make sure you're logged in as an admin user - this is required to change user roles.

The plugin requires the Roles framework - make sure you install and enable that one first.

Release Notes:

Initial release


  • TahoeBilly 787 days ago

    Now we are talking. This looks to be a big step in getting Elgg groups really rolling.

  • dinesh 784 days ago

    nice job,,,

  • Kai 779 days ago

    Hello it doesn't work,

    I have installed the Roles Framework, then Moderator roles and Administrator for Roles. When I change a user into a Group moderator, and after that when this new Moderator goes online, the site is not available, internal error 500. 


    What is the reason?

    Best regards.

    Kai http://dunkle-biene.honey-bees.de

  • ivanoman 778 days ago

    how to extend the role in order to give only the grpup admin the possibility to create event, blog, upload file ?


  • ivanoman 778 days ago

    In the pluging where is the instruction to show or hide the button create group ?

  • ivanoman 775 days ago

    I would like that only group admin can post into a group and may be create only the event.
    Can you just help me in pne of this thing the rest I will do myself.
    Just to understand where to start..


  • Andras Szepeshazi 774 days ago

    @Ivano Detailed documentation is included with the plugin under docs/manual.pdf. Make sure you read that first. If you have any specific question after reading the docs, fire away.

  • ivanoman 774 days ago

    Hi Andras,

    I'm reading the documentation and snow the fog is going a little bit.

    Analizing the code I see this:

    'pages' => array(

                        'groups/add/{$self_guid}' => array('rule' => 'deny'),

    I suppose this is the code that hide  the create button. How can I identify all the others components in the page like upload file and so on ?

    Or more difficoult how do I recognise the field that show the list where it says to post into the group / public / ..... in order to decide that if an user is a group member he can only post into the group ?

    Thank you very much




  • Andras Szepeshazi 774 days ago


    "I suppose this is the code that hide  the create button."

    Exactly! Cool that you found it.

    "How can I identify all the others components in the page like upload file and so on ?"

    Most probably they will all be called "PLUGIN_NAME/add/{$self_guid}", where plugin name can be "file", "bookmark", "groups", etc. Try this, if it does not work, then I'm afraid you'll have to look at the code of the relevant plugin.

    "Or more difficoult how do I recognise the field that show the list where it says to post into the group / public / ..... in order to decide that if an user is a group member he can only post into the group ?"

    I'm afraid I don't understand what you need here. Pls give me examples like User "A" is member of Group "B", and I'm trying to disable User "A" uploading a file to Group "B".


  • Andras Szepeshazi 774 days ago

    @Ivano LOL my bad, the configuration to hide the create button on group pages is

    'menus' => array(
      'title::add' => array(
      'rule' => 'deny',
      'context' => array('groups')



    So for disabling the file create button, just add "file" to the context filter, like: 'context' => array('groups', 'file')




  • ivanoman 774 days ago

    Thanks Andras.
    I'm courious to know what " 'groups/add/{$self_guid}' => array('rule' => 'deny')" do .

    then if you are a member of a group and you are posting a blog you have the possibility to give access to public / private / auth user / group . I would like to configure in order that a user can post only into a group.

    Sorry for my bad english.

  • ivanoman 771 days ago

    Hello Andras,
    I've applier your suggestion and is working fine but with one exception.

    If the user have joined a group in the group main page there is a file widget that show "Upload File". So the user can upload file.

    How can I trap this ?

  • ivanoman 770 days ago

    Andras where are you ?
    I need your help please give me an hit


  • ivanoman 770 days ago

    I'm more precise now that I've discover where the link to create a new file is located.


    $new_link = elgg_view('output/url', array(
        'href' => "file/add/$group->guid",
        'text' => elgg_echo('file:add'),
        'is_trusted' => true,

    How to hide it using the role ?

  • Andras Szepeshazi 770 days ago

    @ivanoman Try this:

    1. copy the file from mod/file/views/default/file/group_module.php to mod/roles_group_admins/views/override/default/file/group_admin.php

    2. From the new file, remove the reference you've found (that adds the "create new file" link)

    3. In the group admin role configuration, under default role section, add this:

                        'file/group_module' => array(
                            'rule' => 'replace',
                            'view_replacement' => array(
                                 'location' => 'mod/roles_group_admins/views/override/',

    With that you essentially override the original group module file view. Hope this helps, I haven't tested it but the approach should work.

  • ivanoman 769 days ago

    Dear Andras.
    thanks for your precious suggestion.
    I've tried but is not working. Seems that is not overriding.
    I'm trying to move the code inside the start.php but apparently nothing change.

  • Andras Szepeshazi 769 days ago

    @ivanoman You probably misplaced the new permission rule, it should be under the views section, for DEFAULT_ROLE. I tested this and works as expected. I created a gist for you with the necessary modifications, take a look here.

  • ivanoman 769 days ago

    Andras you are magik !!!
    Thank you very very much.
    Is working fine !

    NOw i go on to personalize the other link.
    Have a wonderfull Sunday.

  • ajojavi 711 days ago


  • rjcalifornia 704 days ago

    Hi @Andras

    I was trying to make a new role.

    I hide the 'add group' button but when I try to hide the 'edit group' it doesn't work. Also when I try to deny access to 2 pages (create blog and create group) only one rule work and the other won't

    Am I missing something? I read the docs and I can't find the answer :(

  • Andras Szepeshazi 704 days ago

    @rjcalifornia Can you please show me your configuration code? Put it up to github, as a gist: https://gist.github.com/


  • rjcalifornia 702 days ago

    @Andras Thanks for the response, sory for the delay hehe


    Ok, here's the gist:


    And another quick question. How can I deny access to the Administration Dashboard?

  • Andras Szepeshazi 702 days ago

    @rjcalifornia You have multiple issues in your configuration file. The "pages" section of your configuration array is duplicated, while the role plugin expects only a single section for each key ("menus", "actions", etc). When defining multiple rules for a section, they should be listed within the section, so

    "pages" => array(






    I didn't see any attempt in your config to hide the "edit group" button, so I don't know what problem you have bumped into. For denying access to the Admin dashboard, have a look at the roles_moderator plugin for hints.

  • rjcalifornia 702 days ago


    Thanks! It is working now! However, I was looking at the docs and also at the group moderators and roles moderators plugins and I tried to deny the 'edit group' action and it didn't work.

    I also tried to deny access to the 'edit group' page with no results. Here's the code:



    What else am I missing? It looks right, however I don't know.

  • rjcalifornia 702 days ago

    Oh btw your suggestions worked!! Thanks!!!!!!