İ found a solution:
$posts = get_queried_object();
echo $posts->count;
Related Posts:
- How to display by default only published posts/pages in the admin area?
- Using single.php from plugin folder instead of default template folder
- Static posts page with home.php
- Pagination not working on Custom Page Template
- Why does `url_to_postid` return 0 when testing `page_for_posts` Page?
- Remove custom posts that match taxonomy value
- Using Custom Posts with Metaboxes and Drop-downs
- Is there any WordPress alternative to Book module of Drupal?
- disable column on post and user list
- Posts vs. Pages
- How to display data in archive page?
- Set terms in a custom post
- Get posts of ONE taxonomy term of custom post type
- Adding buttons to Add New Post and Add New Page
- Duplicate Custom Post Type and Taxonomy Slug
- Remove Custom Post Type Slug and add Custom Taxonomy to Permalink Structure?
- Static posts page with home.php
- 404 error on default post type and default taxonomy fronted page
- How do I insert a post with custom post type and relate it to a custom taxonomy?
- “about us”, ” contact” sections should be article(post) or page in the simple small Business website?
- disable Tab post on nav-menus page (Admin)
- relating business and products with custom taxonomy?
- WordPress Query Posts From Category Post on Static Page
- Organization of time insensitive content
- How To Use Custom Tax of a Post Type
- How to output all taxonomy links from a custom post type in a menu?
- What would causes search to return incorrect results?
- Changing permalink of WordPress
- Added a ACF field to custom page and want the results to show as a column in admin
- Put page on Archived statut after end of publication date
- post and page and custom post type
- Page with Category Returning 1
- Customizing URL slugs of Custom Post Type and Taxonomy make posts/pages 404
- How do I set content in my pages so that it remains permanent while blog posts are added below?
- Permalink base only for posts
- Multiple Custom Post Type loop logic
- How to list all names and descriptions of a custom taxonomy
- Allow users to create their own page/s
- 404 for some custom taxonomy not ALL taxonomy
- Make a custom URL and link to custom Template
- Special Query: Title, Terms, Content – %LIKE%
- Automatically delete default posts and pages on theme install?
- How to have more post in a page than in your home page
- custom post type single page template not working
- Adding Count Post in Page
- Taxonomy Category category.php not working
- How to have 2 posting pages on a blog
- Edit Page button is gone
- Determine if page is the Posts Page
- Difference between an archive and a page listing posts
- Custom Post Types, slug, archive and SEO plugins
- Search Custom Post Type Pages and Custom Fields in 2 Dropdowns?
- disable password protected page for logged users
- Unattaching images from a post
- Alternate custom content in the loop
- How can I add a meta-box to the posts editor containing all items of a custom taxonomy as checkbox?
- How to show featured image in custom post type dashboard post page
- Private Posts/Pages & Search
- White Blank Page when Updating and Publishing Page/Post
- Dynamic carousel on individual posts
- How to add pagination in between post and comments?
- Pass data between pages
- Add Word Limit to Posts
- Print all the tags from a custom post type Please
- Display multiple custom taxonomy values on single custom post types page?
- Custom loop pagination links not working
- wp-cli post create & media import issues
- Getting value from get_post_custom
- Set Default Category to Username
- show custom post type category dropdown sorting result on same page
- Dynamically switch template on click
- Tell WP to use a specific template file in posts
- How to detect when admin user is on the All Posts page?
- Two Custom Post Types with Identical Articles Competing for the same Slug
- Custom Permalink Structure for Pages & Posts
- Getting a “404 Not Found” error when “Preview Changes” is clicked
- if in category but only with post meta
- My Custom Post Type Still Using index.php
- Custom home page with full post for first one only
- Post/page title to permalink transformation – what is behind the scenes?
- Would a “hub” page work better as a page or a post?
- Page of posts made to look like homepage
- How to link post titles on page A to its posts on page B?
- Custom post type slideshow background images to insert in a plugin
- Trying to exclude custom posts based on date, while sorting by custom field
- Permanently deleted posts still exist
- Deleted page still shows and is showing posts archive
- Display Custom Post Category Count & WordPress Category Count Using Shortcode
- My posts page is missing the page title
- Alternative content between posts no repetition
- Add Categories To Custom Post
- Is it possible to query a category with specified posts?
- Custom Single Post Type not referring to single-post-type.php File
- Theme does not respect spaces between paragraphs in pages
- My blog “page” used to show a list of posts, but now it’s just showing the page content?
- “Current” class on a singular page menu item with custom post types?
- get next/previous post name
- Display ONLY Latest Post From Several Categories
- how to show all type of author posts in author page (SOLVED)
- WordPress Page Column Problem [closed]