users_can_register_signup_filter() WordPress Function
The users_can_register_signup_filter() function allows you to filter whether a user can register on your site. This can be useful if you want to allow registration only for certain users, or if you want to disable registration altogether.
users_can_register_signup_filter() #
Determines whether users can self-register, based on Network settings.
Return
(bool)
Source
File: wp-includes/ms-functions.php
function users_can_register_signup_filter() {
$registration = get_site_option( 'registration' );
return ( 'all' === $registration || 'user' === $registration );
}
Expand full source codeCollapse full source codeView on TracView on GitHub
Changelog
| Version | Description |
|---|---|
| MU (3.0.0) | Introduced. |