gppa_query_limit
Description
Adjust the maximum number of results that can be returned in a GP Populate Anything query.
Usage
Apply to all applicable fields on all forms.
add_filter( 'gppa_query_limit', 'my_custom_function' );
Apply to all applicable fields on a specific form.
add_filter( 'gppa_query_limit_FORMID', 'my_custom_function' );
Apply to a specific field on a specific form.
add_filter( 'gppa_query_limit_FORMID_FIELDID', 'my_custom_function' );
Parameters
query_limit int
Query limit to be passed onto Object Type queries.
object_type GPPA_Object_Type
Current object type.
field GF_Field
The current field being populated.
Since
This filter is available since GP Populate Anything 1.0.
The $field
parameter and FORMID/FIELDID support was added in 1.0-beta-4.44.
Examples
Change the query limit to 750 for all dynamically populated fields.
Change the query limit to 750 for only the post object type.
Change the query limit to 1000 for a specific field on a form.
In this example, we increase the query limit to 1,000 for field 4
in form 123
.