Skip to:
Content
Pages
Categories
Search
Top
Bottom

Group creation: bypass group creation settings form step..


  • rsandilands
    Participant

    @rsandilands

    We only only want to allow our members to create hidden groups, and to allow all group members to invite others, to post to activity feed and to also send group messages.

    I can see that group-settings.php sets up the form with these options but ideally we’d like to bypass the settings page in group creation as we aren’t allowing any choices here for the group creator.

    For now I’ve simply removed the redundant radio button fields and set the resining radio button to be checked so the values are carried through the multipart form but ideally I’d skip the group-settings.php options.

Viewing 1 replies (of 1 total)

  • nehilmehta
    Participant

    @nehilmehta

    Hi,

    You can use below custom code to select hidden as default radio button

    function rizen_make_new_group_hidden( $group_ref_array )
    {
    if ( current_user_can( ‘manage_options’ ) )
    {
    return $group_ref_array;
    }

    $group_ref_array->status = ‘hidden’;

    return $group_ref_array;
    }
    add_filter( ‘groups_group_before_save’, ‘rizen_make_new_group_hidden’ );

    I am still looking to get the default option to select the radio button to create group by all members. If you have any luck, pls. share.

    Thanks

Viewing 1 replies (of 1 total)
  • You must be logged in to reply to this topic.
Skip to toolbar