PDA

View Full Version : Show the Posters Primary and Secondary usergroups in Post Bit Legacy


cardealercheck
02-12-2013, 12:26 AM
I'm looking for how you can show the posters (NOT post reader's) primary and secondary usergroups in Post Bit Legacy

I see that I can show the primary usergroup like
<vb:if condition="$post['usergroupid'] == 7">Show something based on posters primary user group</vb:if>


What would I use in place of usergroupid if I wanted the condition to be based on checking both the primary and secondary user groups of the poster

LifesGreatestGift
02-12-2013, 12:46 AM
does that conditional not work?

cardealercheck
02-12-2013, 12:49 AM
In my testing it seems to only work for the posters Primary only.

I'm trying to get a display based off of the posters Primary and Secondary usergroups.

LifesGreatestGift
02-12-2013, 12:53 AM
<vb:if condition="is_member_of($post, 2, 5, 7 )">Do this if in group 2, 5 or 7</vb:if>

cardealercheck
02-12-2013, 05:16 AM
Works perfectly, thank you so much!

Since I wanted to show something different on each line by usergroup I set mine up like this using your code where 7 was the primary user group and 26 was the secondary.

<vb:if condition="is_member_of($post, 7 )">
Special text for usergroup7
</vb:if>
<vb:if condition="is_member_of($post, 26 )">
Special text for usergroup26
</vb:if>

The if's go on through about 15 different usergroups but it does the job perfectly.