Filters whether a user should be added to a site.
$user_id, $blog_id = 0, $reassign = 0
Sortie :
@param true|WP_Error $retval True if the user should be added to the site, error @param int $user_id User ID. @param string $role User role. @param int $blog_id Site ID. @param int $user_id User ID. @param string $role User role. @param int $blog_id Blog ID. @param int $user_id ID of the user being removed. @param int $blog_id Optional. ID of the blog the user is being removed from. Default 0. @param int $reassign Optional. ID of the user to whom to reassign posts. Default 0. @return true|WP_Error True on success or a WP_Error object if the user doesn't exist.
// Utilisation de la fonction remove_user_from_blog
$result = remove_user_from_blog($user_id, $blog_id = 0, $reassign = 0);
if ($result) {
// Votre logique ici
}
Chargement des actualités...