MyBB Community Forums

Full Version: New field in mybb_users for storing banned users?
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
I added an "isbanned" field to mybb_users where "1 = true" and "0 = false". It is required for a program I am using. And before you ask, it cannot be configured to look for the banned GID in the usergroups field.

How can I automatically update my new "isbanned" field to "1" when I ban a new user ?

This is for mybb 1.6.3
A) Upgrade to 1.6.5 Smile
B) It can look at the usergroup fields in mybb_users to see if the usergroup is 7. 7 is the default "Banned" Group.

Or

C) make a plugin that hooks to modcp_do_banuser_end and admin_config_banning_add_commit. Also, you may want to add hooks to admin_config_banning_delete_commit and modcp_liftban_end for unbanning.