![]() |
Can I check for banned user in a template?
How can I check in a template to see if a user is banned? I tried just checking for the banned usergroup, but that doesn't seem to work. What could I be doing wrong?
Here is what I'm using: <if condition="$bbuserinfo['usergroupid'] == 19"> but the banned users seem to pass that conditional right over. :confused: |
Use
<if condition="$post[usergroupid] == 19"> or remove the ' <if condition="$bbuserinfo[usergroupid] == 19"> |
Hmmm, neither seem to work. I'm doing a bunch of checking in the header to see if a user is in different groups. All the others seem to work just fine. Is there some sort of limit on IF ELSE statements I can do? I currently have 4 lined up...
|
Depending on what template you're trying to check...
Code:
<if condition="is_member_of($bbuserinfo,9)">You're banned.</if> What exactly are you trying to do? |
Got it! It was actually a problem with template changes not trickling down. Basically, I'm stupid.
Anyway, when using that is_member_of, it will check for secondary groups too, right? |
Yep, that's why it's better to use than $bbuserinfo[usergroupid].
|
All times are GMT. The time now is 05:31 AM. |
Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|