Allow customizing capabilities prefix through wp-config.php
|Reported by:||hudatoriq||Owned by:||hudatoriq|
|Component:||Role/Capability||Keywords:||has-patch needs-review early|
It's better if we are able to customize the user capabilities prefix. There are some advantages:
- Security improvement.
- Allow users to customize their multiple WP installations and share single user table & capabilities information without hacking the core script.
Right now the user capabilities prefix is always the same as the $table_prefix.
For user table sharing, some people have been practicing it. See this forum thread. We share a database, set different $table_prefix for each installation, define the CUSTOM_USER_TABLE and CUSTOM_USER_META_TABLE into the same value. The only problem is, we can't share the same user capabilities list since we can't set the prefix to other value than $wp_prefix. This could be improved if we add conditional statement to see whether the capabilities prefix is already defined in somewhere else (e.g. wp-config.php).
Change History (15)
comment:1 @hudatoriq — 6 years ago
- Keywords has-patch added; custom user capabilities prefix removed
- Keywords needs-docs added; tested commit removed
- Milestone changed from 2.8 to 2.9
- Priority changed from high to normal