[buddypress-dev] [BuddyPress] How to programmatically add an user to a group

Erick Hitter ehitter at gmail.com
Mon Jun 27 10:19:55 UTC 2011


I've got sample code that does just that at
http://www.ethitter.com/tips-tricks/2010/11/automatically-add-new-users-to-a-buddypress-group/.
In this example, the user is added automatically after activating his/her
new account, but hooking the sample code to a different action that provides
a user ID (such as a login action) will produce the desired result.

Erick

On Mon, Jun 27, 2011 at 03:12, Pasquale Puzio <pasquale.puzio at gmail.com>wrote:

> Hi friends,
>
> I would know if in BuddyPress there is some function or some plugin
> that allow me to automatically add an user to a group. I need that
> because it's an important function of my work-flow.
>
> If there aren't, could someone post here a sample code to do that?
>
> Thanks
>
> --
> Dott. Pasquale Puzio
> http://www.pasqualepuzio.it
> info at pasqualepuzio.it
> 340 5026359
> _______________________________________________
> buddypress-dev mailing list
> buddypress-dev at lists.automattic.com
> http://lists.automattic.com/mailman/listinfo/buddypress-dev
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.automattic.com/pipermail/buddypress-dev/attachments/20110627/23b8a963/attachment.htm>


More information about the buddypress-dev mailing list