Field :: posts_per_page

Controls the number of search results displayed per page.

Parameters

label
(string)
Default: None
format
(string) 'select', 'multi-select', 'checkbox', 'radio', 'text', 'hidden', 'number', 'color', 'url', 'email', 'tel', 'date', 'datetime', 'time', 'week'
Default: text
default
(string)
Context: An integer value (ie 1,2,3, etc.)
Default: None
values
(array)
Context: An array of integer values
Default: None

Example

A posts_per_page field allowing the user to display either 5 or 10 results per page.

$args['fields'][] = array(
                    'type' => 'posts_per_page',
                    'values' => array(5=>'5',10=>'10'),
                    'default' => 5,
                    'format' => 'radio');