Linux 软件免费装
Banner图

Membership & User Roles for WooCommerce (Automatic Role Changer)

开发者 DaveFX
更新时间 2026年11月22日 03:09
捐献地址: 去捐款
PHP版本: 8.0 及以上
WordPress版本: 7.1
版权: GPLv3
版权网址: 版权信息

标签

membership subscriptions access control restrict content user roles

下载

20260824 20260826 20260827 20260828 20261121 20240616 20201217.2 20240319.1 20261007 20201115 20201217.1 20250130 20261008 20201217 20250122.1 20250127 20250204 20250325 20240319 20250122 20250203 20260522 20260522.1 20260522.2 20260522.3 20260728 20260813 20260521 20260817 20260822

详情介绍:

安装:

Prerequisites Steps

常见问题:

  1. What happens if a user purchases multiple products with different role assignments?

The plugin can be configured to add roles, or to replace roles.

  • If the plugin is configured to replace roles, the user will remain with the last-assigned role.
  • If the plugin is configured to add roles, all the roles will be assigned to the user. We recommend using a plugin like "Members" to manage multiple roles per user.

  1. What happens if a user purchases a product granting a role several times?

In the Premium version, the validity period for a purchase is added to the previously existing one.

  1. Can I assign multiple roles to a single product?

In the Premium version you can assign multiple roles. Users will gain all assigned roles upon purchase.

  1. How do I upgrade to the premium version?

Visit the official plugin page to purchase the premium version. After purchasing, install and activate it like the free version.

更新日志:

20261121 20261008 Security fix. Please update. 20261007 Security fix for "Replace Roles" mode. Please update. What was wrong: since 20260826, Replace Roles mode keeps the roles other plugins give a user (see that version's notes). To do so it remembered those roles, and it kept remembering them even after the other plugin had taken them away. So a role that had been legitimately revoked could come back on the user's next purchase of a role-mapped product... including Administrator, if some other mechanism had once made that user an administrator and later removed it. Who is affected: only sites using Replace Roles mode on versions 20260826, 20260827 or 20260828, and only for a user who had a role revoked by something other than this plugin while this plugin was managing their roles. The default "Add/Remove Roles" mode was never affected. What changed: a role this plugin did not grant is now kept only while the user actually holds it. The moment it leaves the user (whoever removes it) it is forgotten, and it is never put back. Administrator is never remembered at all, and the dfx_woo_role_changer_foreign_roles filter can no longer add a role the user does not have. What you should do: if you used Replace Roles mode on one of the affected versions, take a quick look at Users → Administrators after updating and make sure everyone on that list should be there. Thanks to Azgnt for reporting this through the Wordfence bug bounty program. 20260828 20260827 20260826 Behaviour change in "Replace Roles" mode. Read this if you use that mode. What changed: until now, granting a role in Replace Roles mode wiped every role the user had. From this version it replaces only the roles this plugin granted, plus the role the user had when the plugin first acted on them. Any role a different plugin gave the user is kept. Why: wiping everything destroyed roles other plugins were actively managing — WooCommerce Subscriptions' subscriber role, Members, MemberPress, anything that assigns roles. The other plugin restored its role on its next event, this one wiped it again on the next grant, and the two fought indefinitely. The user's role ended up depending on which plugin ran last. What you will notice: if this is the only plugin managing roles on your site, nothing changes at all. If another one is, its roles now survive instead of disappearing. If you actually want a single role and nothing else, a site can restore the old behaviour with the new dfx_woo_role_changer_foreign_roles filter, returning an empty array. No provider is detected or named: a role counts as foreign simply because this plugin never granted it. 20260824 20260822 20260817 20260813 20260728 20260522.3 20260522.2 20260522.1 20260522 20260521 20250325 20250204 20250203 20250130 20250127 20250122 20250121 20240616 20240319 20201115