Skip Navigation

[Resolved] Return number of total items outside view limit

This support ticket is created 4 years, 6 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.

Sun Mon Tue Wed Thu Fri Sat
- 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 9: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/Hong_Kong (GMT+08:00)

Tagged: 

This topic contains 1 reply, has 2 voices.

Last updated by Luo Yang 4 years, 6 months ago.

Assisted by: Luo Yang.

Author
Posts
#1885341

I am building a "view all" feature using bootstrap modal using two views. The first View lists a limited number of items in the page and a "view all" button, which opens the second unlimited view in a bootstrap modal lightbox.

I would like to conditionally display my "view all" button as well as display the total unlimited query results in the first view. Unfortunately [wpv-found-count] and [wpv-items-count] shortcodes will only ever return the limited number set in the first view's "Limit and Offset" display option.

I have found a few related topics in the forum instructing to put the [wpv-found-count] shortcode outside of the loop to do this. However, no matter where in the loop editor I place this shortcode It is always limited.

You can see the value of [wpv-found-count] in the "Media Mentions" block on this page: hidden link

#1885815

Hello,

You just need to move the "View All" button into the second post view, section "Loop Editor", then the shortcode [wpv-found-count] will be able to output correct number of second view.

More help:
https://toolset.com/documentation/user-guides/views-shortcodes/#wpv-found-count