@webzunft
Active 2 months, 1 week ago
-
Thomas M replied to the topic how to add new members to groups automatically? in the forum How-to & Troubleshooting 4 months, 1 week ago
The following code works for me:
function automatic_group_membership( $user_id ) {
if( ! $user_id ) {
return false;
}groups_invite_user( array( 'user_id' => $user_id, 'group_id' => $group_id ) );
}
add_action( 'bp_core_activated_user', 'automatic_group_membership' );
add_action( 'user_register', 'automatic_group_membership'…[Read more]