This plugin gives you the ability to disable specific user accounts via a profile setting.
Once installed and activated, a checkbox appears on the user profile settings (only for admins). When checked, the user’s account will be disabled and they will be unable to login with the account. If they try to login, they are instantly logged out and redirected to the login page with a message that notifies them their account is disabled.
This can be useful in a few situations.
- You want freelance writers to still show up in the authors box, but you don’t want them to be able to login.
- You have former employees who have authored posts and you don’t want to delete them or reassign their posts to other users, but still need them to show up in the “Authors box.”
- You are working on a site for a client who has an account, but do not want him to login and/or make changes during development.
- You have a client who has an unpaid invoice.
This plugin is on GitHub! Pull requests are welcome. If possible please report issues through Github.
- Upload or extract the
disable-user-loginfolder to your site’s
/wp-content/plugins/directory. You can also use the Add new option found in the Plugins menu in WordPress.
- Enable the plugin from the Plugins menu in WordPress.
- Edit any user and then look for the “Disable User Account” checkbox.
- Bulk Disable/Enable user accounts by selecting one or more user accounts and then choosing Enable or Disable from the bulk actions menu.
Can I change the message a disabled user sees?
Yes, there is a filter in place for that,
توسعه دهندگان و همکاران
“Disable User Login” نرم افزار متن باز است. افراد زیر در این افزونه مشارکت کردهاند.مشارکت کنندگان
- Add hooks for multisite.
- Permission fix on quick links.
- Translation updates.
- Fix to disable application passwords (fixes #7).
- Add user enable/disable quick links.
- Bump WP tested version.
- Static method to return user meta key
- Fix some comments
- Update to prevent disabling super admins on bulk disable.
- Update to check user edit permission on bulk disable.
- Updated to prevent current user from disabling his/her own account on bulk disable.
- Force disabled users to logout.
- Tested up to WP 5.7
- Tested up to WP 5.6
- Add action hooks when user accounts are enabled/disabled and when disabled user attempts to login.
- Switch to
authenticatefilter for user login.
- Multisite support.
- Version bump.
- Initial version.