filtrod 6.4.0
unzip_file
Opis — z kodu źródłowego
Filters the result of unzipping an archive.
Parametry
| Parametr | Typ | Opis |
|---|---|---|
$result | true | \WP_Error | The result of unzipping the archive. True on success, otherwise WP_Error. Default true. |
$file | string | Full path and filename of ZIP archive. |
$to | string | Full path on the filesystem the archive was extracted to. |
$needed_dirs | string[] | A full list of required folders that were created. |
$required_space | float | The space required to unzip the file and copy its contents, with a 10% buffer. |
Wywołanie
Rejestracja callbackaphp
// rejestracja funkcji zwrotnej — podaj liczbę argumentów!
add_filter( 'unzip_file', 'twoja_funkcja', 10, 5 );
function twoja_funkcja($param_1, $param_2, $param_3, $param_4, $param_5) {
// Twój kod
}
// rejestracja funkcji zwrotnej — podaj liczbę argumentów!
add_filter( 'unzip_file', 'twoja_funkcja', 10, 5 );
function twoja_funkcja($param_1, $param_2, $param_3, $param_4, $param_5) {
// Twój kod
}Popularne w tej kategorii