Skip Navigation

[Gelöst] problem with filter and count items

This support ticket is created vor 4 Jahre, 11 Monate. 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.

No supporters are available to work today on Toolset forum. Feel free to create tickets and we will handle it as soon as we are online. Thank you for your understanding.

Sun Mon Tue Wed Thu Fri Sat
- 10:00 – 13:00 10:00 – 13:00 10:00 – 13:00 10:00 – 13:00 10:00 – 13:00 -
- 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 -

Supporter timezone: Asia/Kolkata (GMT+05:30)

This topic contains 35 Antworten, has 2 Stimmen.

Last updated by Minesh vor 4 Jahre, 9 Monate.

Assisted by: Minesh.

Author
Artikel
#1234531

Hi,

i have a filter for a view of subelements of CPT- it counts wrong with [wpv-items-count] Objekte von [wpv-found-count]

it add always one item in it! - That means in Frontend it shows 2 items but it count 3!

here is the Problem
hidden link

What can i do? What ist wrong.

#1234815

Minesh
Supporter

Languages: Englisch (English )

Timezone: Asia/Kolkata (GMT+05:30)

Hello. Thank you for contacting the Toolset support.

First of all - After checking to debug information you shared with us, I found that you are using outdated Toolset plugins. We always recommend running your site with latest stable release plugin version.

We publish the Types 3.0 with the new many to many relationships and we have added the number of new features to this major release almost a year ago.

Please check the following blog:
=> https://toolset.com/2018/05/toolset-post-relationships-release/
=> https://toolset.com/2018/05/when-if-to-migrate-relationships-in-old-toolset-sites/

Before you update the Toolset plugins to latest official release version:
*** Please make a FULL BACKUP of your database and website.***

Please try to follow the following steps.
- Deactivate and Delete all Toolset plugins from the plugins page
- Download the latest Toolset Types plugins from your accounts page:
=> https://toolset.com/account/downloads/
- Upload and activate Types plugin using plugins page

Then, as you already installed the latest Types plugin, you will be able to install other plugins using the installer. Please check the following Doc and try to follow the steps:
=> https://toolset.com/faq/how-to-install-and-register-toolset/#automatic-installation-once-you-have-types-plugin-installed

Please let me know if you still see the issue with updated plugins.

#1234878

HI Minesh, yes, but i need this plugin versions to load the site in this version. All is good, but this only issue is wrong. I have a ticket from 7 month ago about this.
+
But i need help. 😉

you wanna have a login?

thx - alex

#1234885

Minesh
Supporter

Languages: Englisch (English )

Timezone: Asia/Kolkata (GMT+05:30)

Well - I just checked with my test install and it just works fine.

As you can see I've 14 items available:
=> hidden link

With view, I've set the pagination to display 3 results per page and when I added the shortcode:

[wpv-items-count] Objekte von [wpv-found-count]

It displays the correct numbers on frontend, please check the following screenshot:
=> hidden link

Am I missing any step to reproduce this issue?

#1234891

Hey, yes but in my case it always add one + when i use the filter. Look for yourself: hidden link

thx for an hint - perhaps can i manipulate the initial state of shortcode like [wpv-found-count -1] ?

alex

#1234900

Minesh
Supporter

Languages: Englisch (English )

Timezone: Asia/Kolkata (GMT+05:30)

Well - I checked again by adding the custom filed filter as radio button and when I select the radio button it still displayed the correct results. Please check the following screenshot as proof:
=> hidden link

Again, I would recommend you to take the decision to update the plugins sooner or later, as more delay may affect your site more and it might be get broken. We also removed Types from WordPress, please check the following blog post:
=> https://toolset.com/2019/04/toolset-types-removed-from-wporg/

I just wanted to check your view settings now and for that I need access details and I will try to build view with the same settings you have and try to reproduce the issue.

*** Please make a FULL BACKUP of your database and website.***
I would also eventually need to request temporary access (WP-Admin and FTP) to your site. Preferably to a test site where the problem has been replicated if possible in order to be of better help and check if some configurations might need to be changed.

I have set the next reply to private which means only you and I have access to it.

#1235404

Minesh
Supporter

Languages: Englisch (English )

Timezone: Asia/Kolkata (GMT+05:30)

Well - thank you for sharing access details but when I try to access wp-admin it ask me for authorization access.

Can you please share authorization access details.

In addition to that, with your last reply, you added that you have issue with the content template but first we will try to solve your original issue of the count.

I have set the next reply to private which means only you and I have access to it.

#1235406

Hi the first htaccess authentication is:
user: staging
pass: ezIyemut.906

#1235411

Minesh
Supporter

Languages: Englisch (English )

Timezone: Asia/Kolkata (GMT+05:30)

Well - I checked on your install now and I see the query returns the 24 posts and it displays 24 posts on the frontend.

Looks like it was cashing issue, I've disabled the caching plugin for now, Can you please confirm you see 24 items.
=> hidden link

#1236016
Bildschirmfoto 2019-04-26 um 10.41.48.png

Hey, no,

if i make some Filtersetting e. g. Screenshot - it shows the wrong count:

thx for helping - alex

#1236088

Minesh
Supporter

Languages: Englisch (English )

Timezone: Asia/Kolkata (GMT+05:30)

Well - view's return the correct output.

Iv'e created the following test view that queries same post type:
=> hidden link

I've added the above view to a new test page here:
=> hidden link

[wpv-view name="toolset-test-view" wpvprchildof="5395"]   5395 is the parent post ID 

Now, when you check on frontend:
=> hidden link

- By default it displays 24 results
- now, click on radio button 2 and you will see that it will display 5 post entries and count also displayed as 5

Please check the following screenshot:
=> hidden link

What I noticed is that when you are displaying the view with slider on your original page:
=> hidden link

Slider skips the first entry, so first entry is not rendered by slider. That is why you see 4 boxes with slider but acutally view is returning 5 results as you noticed with test page I've created here:
=> hidden link

Strange thing is that, it does render the results if you switch your filter to work with submt button (no ajax), so on your original page the issue is on filter slider does not able to render the first entry. I do not see the issue is from the view.

#1244942

Hey can i fix the thing with manipulating it e. g. with jquery? - thx for an answer

#1244945

Minesh
Supporter

Languages: Englisch (English )

Timezone: Asia/Kolkata (GMT+05:30)

Yes - but you need to write that custom jQuery code as required and check if that helps I already pinpoint you what's going on with your setup and your custom slider and why its not working.

#1244955

Hey, i dont know why it is the same as the gallery above! - it dot cut the first item.. - can you help?

thx - alex

#1244961

Hey, when i dont use ajax - it works! - can you tell me a hint?

thx. - alex

This ticket is now closed. If you're a WPML client and need related help, please open a new support ticket.