Add the above to your Toolset custom code section in Toolset->Settings->Custom Code and activate it. You will need to replace "covid-19-info" with the slug of your post type that you want to count the users for.
This support ticket is created 4 years, 2 months ago. There's a good chance that you are reading advice that it now obsolete.
This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.
Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.
Hi there. I am using views to display infos that are uploaded via cred form to my page. On the landing page i want to display some statistics.
And there is one part where i am stuck since this morning:
I want to display the number of active members that posted at least one post / info.
So I am using a view to search for all members. And then i wanted to use a second view inside that first one to filter out the number of members that have published something... I can´t make it....
Essentially you want to only display the users that have created posts correct? So if they haven't made any posts you don't want to display them in the list that your view is displaying ?
Hi Shane,
actually I just want to display the number of users that have at least posted one post type.
So i have created a member group for users.
They register and can post via cred form.
On one Page i am listing some statistics. And want to show the number of users who have published content.
Hi Shane,
unfortunately this is not working correctly.
When using your shortcode I receive a number of one.
That is the admin, that has posted one post (Hello World).
The Users I want to count have the user role EC Member and the posts i want to count are not "standard blog posts" but custom post types (slug = covid-19-info).
I've revised the code a bit more as I realised that it was not providing the accurate information. I've also allowed it to specify the post type that you want to add the count for.