BP_Signup::check_user_status( int $user_id )
Check a user status (from wp_users) on a non-multisite config.
Description
Parameters
- $user_id
-
(Required) ID of the user being checked.
Return
(int|bool) The status if found, otherwise false.
Source
File: bp-members/classes/class-bp-signup.php
public static function check_user_status( $user_id = 0 ) { global $wpdb; if ( empty( $user_id ) ) { return false; } $user_status = $wpdb->get_var( $wpdb->prepare( "SELECT user_status FROM {$wpdb->users} WHERE ID = %d", $user_id ) ); /** * Filters the user status of a provided user ID. * * @since BuddyPress 2.0.0 * * @param int $value User status of the provided user ID. */ return apply_filters( 'bp_core_signups_check_user_status', intval( $user_status ) ); }
Changelog
Version | Description |
---|---|
BuddyPress 2.0.0 | Introduced. |
Questions?
We're always happy to help with code or other questions you might have! Search our developer docs, contact support, or connect with our sales team.