c_ws_plugin__s2member_option_forces
public class c_ws_plugin__s2member_option_forces
3.5
( 8 Methods ) Method Summary | |
---|---|
public static array | check_bp_mms_register_access(array $site_options) Register access in BuddyPress, for Multisite compatibility. |
public static str | check_mms_register_access(str $users_can_register) Allows access to the main Multisite Registration Form. |
public static str | check_register_access(int|str $users_can_register) Allows access to the Registration Form. |
public static str | force_default_role(str $default_role) Forces a default Role for new registrations, NOT tied to an incoming payment. |
public static str | force_demotion_role(str $demotion_role) Forces a specific Role to demote to, whenever a Member is demoted in one way or another. |
public static str | force_mms_default_role(str $default_role) Forces a default Role for new Multisite registrations (on the Main Site) NOT tied to an incoming payment. |
public static str | mms_allow_new_users(int|str $allow) Allows new Users to be created on a Multisite Network. |
public static int|str | mms_dashboard_blog(int|str $dashboard_blog) Forces a Multisite Dashboard Blog to be the Main Site. |
public static array check_bp_mms_register_access(array $site_options)
Register access in BuddyPress, for Multisite compatibility.
BuddyPress bypasses the default Filter pre_site_option_registration
, and instead uses: bp_core_get_root_options()
.
3.5
add_filter("bp_core_get_root_options");
add_filter("bp_core_get_site_options");
(before BuddyPress v1.5).
array $site_options - Expects array of BuddyPress site options.
array - Site options array, after having been Filtered by this routine.
public static str check_mms_register_access(str $users_can_register)
Allows access to the main Multisite Registration Form.
3.5
add_filter("pre_site_option_registration");
str $users_can_register - Expects ( none
, all
, blog
, user
), passed through by the Filter.
str - One of none|all|user
; depending on several factors.
public static str check_register_access(int|str $users_can_register)
Allows access to the Registration Form.
3.5
add_filter("pre_option_users_can_register");
int|str $users_can_register - Numeric (1
) or (0
), indicating true or false; passed through by the Filter.
str - Numeric value of (1
) or (0
), indicating true or false; depending on several factors.
public static str force_default_role(str $default_role)
Forces a default Role for new registrations, NOT tied to an incoming payment.
3.5
add_filter("pre_option_default_role");
str $default_role - Expects a default Role to be passed by the Filter.
str - Default Role, as configured by s2Member.
public static str force_demotion_role(str $demotion_role)
Forces a specific Role to demote to, whenever a Member is demoted in one way or another.
Use by the PayPal® IPN routines, and also by the Auto-EOT system.
3.5
str $demotion_role - Expects a demotion Role to be passed by the caller.
str - Demotion Role, as configured by s2Member.
public static str force_mms_default_role(str $default_role)
Forces a default Role for new Multisite registrations (on the Main Site) NOT tied to an incoming payment.
3.5
add_filter("pre_site_option_default_user_role");
str $default_role - Expects a default Role to be passed by the Filter.
str - Default Role, as configured by s2Member.
public static str mms_allow_new_users(int|str $allow)
Allows new Users to be created on a Multisite Network.
3.5
add_filter("pre_site_option_add_new_users");
int|str $allow - Numeric string (1
) or (0
), expected by the Filter.
str - Numeric (1
) or (0
) indicating true or false. Forces to (1
) true.
public static int|str mms_dashboard_blog(int|str $dashboard_blog)
Forces a Multisite Dashboard Blog to be the Main Site.
3.5
add_filter("pre_site_option_dashboard_blog");
int|str $dashboard_blog - Numeric Dashboard Blog ID passed through by the Filter.
int|str - Numeric Dashboard Blog ID, as configured by s2Member. Forces to the Main Site.
Forces WordPress® options.