Exclude Groups by Tag?
@dwenaus: I’ve cloned the default BP groups widget and modified it to display only the group avatars. I have a few “official” groups that I’d like to exclude from displaying in my new widget. They’re all tagged with the same tag, so I was thinking that that might be the best way to go about this.
So, how would I exclude groups tagged with the term “official” from the widget? I’m guessing it has something to do with adding a bit of code to this line in the widget code, I’m just not sure what group tags function to use and if my syntax is correct (or if this is even possible)
while ( bp_groups() ) : bp_the_group(); if(gtags_group_tags() != “official” :
For the record, I’m using the widget on member-header.php to display avatars of the groups the member belongs to. Any help would be appreciated!
You must be logged in to reply to this topic.