filtrod 4.2.0
attachment_url_to_postid
Opis — z kodu źródłowego
Filters an attachment ID found by URL.
Parametry
| Parametr | Typ | Opis |
|---|---|---|
$post_id | int | null | The post_id (if any) found by the function. |
$url | string | The URL being looked up. |
Wywołanie
Rejestracja callbackaphp
// rejestracja funkcji zwrotnej — podaj liczbę argumentów!
add_filter( 'attachment_url_to_postid', 'twoja_funkcja', 10, 2 );
function twoja_funkcja($param_1, $param_2) {
// Twój kod
}
// rejestracja funkcji zwrotnej — podaj liczbę argumentów!
add_filter( 'attachment_url_to_postid', 'twoja_funkcja', 10, 2 );
function twoja_funkcja($param_1, $param_2) {
// Twój kod
}Popularne w tej kategorii