Using Caldera Forms Paginated Queries

Catdera Caldera Forms Banner

These features were added in Caldera Forms 1.7

Caldera Forms 1.7 adds new GDPR compliance tools. Developers will be happy to know that the APIs used to create the GDPR exports and erasers are built on top of other APIs that can be used for custom site development, building add-ons and improving Caldera Forms. This document covers theĀ Caldera_Forms_Query_Paginated class, which uses the Caldera Forms Queries library. The class Caldera_Forms_Query_Pii, which is used for responding to GDPR export and erase requests decorates this class.

Example of Paginated Queries

Here is a basic query for all entries of a form:

By default, there are 25 results per page. You can set it to any number between 1 and 100 using the set_limit method:

You can also select by field value using the Caldera Forms Queries tool.

Where Does This Code Go?

When using WordPress hooks to customize Caldera Forms or other plugins you should not modify the plugin files, or you will lose your changes when you update the plugin. Instead you should create a small plugin to hold the custom code. It's easy, learn how here.

Technically you can add the custom code to your theme's functions.php, but then you will not be able to change your theme and keep these customizations.

Learn More