filtrod 2.8.0
set-screen-option
Opis — z kodu źródłowego
Filters a screen option value before it is set.
The filter can also be used to modify non-standard [items]_per_page settings. See the parent function for a full list of standard options.
Returning false from the filter will skip saving the current option.
Parametry
| Parametr | Typ | Opis |
|---|---|---|
$screen_option | mixed | The value to save instead of the option value. Default false (to skip saving the current option). |
$option | string | The option name. |
$value | int | The option value. |
Wywołanie
Rejestracja callbackaphp
// rejestracja funkcji zwrotnej — podaj liczbę argumentów!
add_filter( 'set-screen-option', 'twoja_funkcja', 10, 3 );
function twoja_funkcja($param_1, $param_2, $param_3) {
// Twój kod
}
// rejestracja funkcji zwrotnej — podaj liczbę argumentów!
add_filter( 'set-screen-option', 'twoja_funkcja', 10, 3 );
function twoja_funkcja($param_1, $param_2, $param_3) {
// Twój kod
}Popularne w tej kategorii