filtrdynamicznyod 2.9.0
{$option}
Args 1Plik wp-admin/includes/class-wp-list-table.php
Opis — z kodu źródłowego
Filters the number of items to be displayed on each page of the list table.
The dynamic hook name, $option, refers to the per_page option depending on the type of list table in use. Possible filter names include:
edit_comments_per_pagesites_network_per_pagesite_themes_network_per_pagethemes_network_per_pageusers_network_per_pageedit_post_per_pageedit_page_per_pageedit_{$post_type}_per_pageedit_post_tag_per_pageedit_category_per_pageedit_{$taxonomy}_per_pagesite_users_network_per_pageusers_per_page
Parametry
| Parametr | Typ | Opis |
|---|---|---|
$per_page | int | Number of items to be displayed. Default 20. |
Wywołanie
Rejestracja callbackaphp
// rejestracja funkcji zwrotnej
add_filter( '{$option}', 'twoja_funkcja' );
function twoja_funkcja($param_1) {
// Twój kod
}
// rejestracja funkcji zwrotnej
add_filter( '{$option}', 'twoja_funkcja' );
function twoja_funkcja($param_1) {
// Twój kod
}Popularne w tej kategorii