WordPress Liczba postów przez użytkownika
echo count_user_posts(USER,'post'); // posts
echo count_user_posts(USER,'page'); // pages
echo count_user_posts(USER,'CUSTOM_POST_TYPE'); // custom post types
// Under a conditional w/ message:
if(count_user_posts(USER,'post') > 10){
echo 'greater than';
} else {
echo 'less than';
}
Fragile Flamingo