Enter your keyword

Blog

Add Shortcode for show total number of Registered Users in WordPress

// Function to return user count  
function wpb_user_count() {  
$usercount = count_users();
$result = $usercount['total_users'];
return $result;
} 
// Creating a shortcode to display user count
add_shortcode('user_count', 'wpb_user_count');

No Comments

Add your review

Your email address will not be published.

* Feilds are Required.