Skip Navigation

[Resolved] Limit output is not working for me

This thread is resolved. Here is a description of the problem and solution.

Problem: I have set the "limit" value in the View editor to be 2, but I see 3 results on the front-end of the site.

Solution: Check the shortcode used to insert the View and remove any limit attributes here, since they will override the settings in wp-admin.

This support ticket is created 5 years, 11 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
8:00 – 12:00 8:00 – 12:00 8:00 – 12:00 8:00 – 12:00 8:00 – 12:00 - -
13:00 – 17:00 13:00 – 17:00 13:00 – 17:00 13:00 – 17:00 13:00 – 17:00 - -

Supporter timezone: America/New_York (GMT-04:00)

This topic contains 2 replies, has 2 voices.

Last updated by Waldo 5 years, 11 months ago.

Assisted by: Christian Cox.

Author
Posts
#1186078

I am trying to: create two columns that show the latest 2 posts, I also need the columns to be responsive so I have chosen your two column view loop option and replaced the HTML table with div tags (I think i did this right)

and I changed the output settings to limit the output to 2 posts, however the output still show the last three options I'm about to include another test post to see if it keeps adding post or if it will stop at three.

here is the loop code I'm using

[wpv-layout-start]
[wpv-items-found]
<!-- wpv-loop-start -->
<div width="100%" class="row wpv-loop js-wpv-loop">
<wpv-loop wrap="2" pad="true">
[wpv-item index=1]
<div class="column">
[wpv-post-body view_template="loop-item-in-vacancies"]
</div>
[wpv-item index=other]
<div class="column">
[wpv-post-body view_template="loop-item-in-vacancies"]
</div>
[wpv-item index=2]
<div>
[wpv-post-body view_template="loop-item-in-vacancies"]
</div>
[wpv-item index=pad]
<div></div>
[wpv-item index=pad-last]
<div></div>
</wpv-loop>
</div>
<!-- wpv-loop-end -->
[/wpv-items-found]
[wpv-no-items-found]
[wpml-string context="wpv-views"]No items found[/wpml-string]
[/wpv-no-items-found]
[wpv-layout-end]

Link to a page where the issue can be seen: dev.opendoorservices.org/vacancies

I expected to see: Only the last two posts in the loop

Instead, I got: three posts in the loop

#1186112

Hi can you share some more information with me?
- Copy + paste the code from the loop-item-in-vacancies template for me to review.
- Check the shortcode you have used to insert this View in the page. If a limit attribute is applied to the shortcode, remove it. This attribute will override the settings you choose in wp-admin:

[wpv-view name="Your View Name" limit="10"]
#1186215

Great it was the short code that showed a limit range thx.

My issue is resolved now. Thank you!