Want to add Number of Products added by each shop manager in users list

you can use this code. It shows the number of products of each user, exactly what you wanted!!! // create tab row in users page add_filter( ‘manage_users_columns’, ‘pre_modify_user_table’ ); function pre_modify_user_table( $column ) { $column[‘pCount’] = ‘product count’; return $column; } // display user product count add_filter( ‘manage_users_custom_column’, ‘pre_modify_user_table_row’, 10, 3 ); function pre_modify_user_table_row( $val, … Read more

Filter and manipulate the get_current_user() function

From what I’m seeing in the github repo. get_current_user doesn’t exist. What you do have is wp_get_current_user, this function does this return _wp_get_current_user(); So now I checked what _wp_get_current_user does. It checks a global variable $global_user, if it’s not empty, return an instance of it (didn’t find any actions for that). If empty it does … Read more