acf/is_field_key
Filters whether the $id is a field key.
Використання
add_filter( 'acf/is_field_key', 'wp_kama_acf_is_field_key_filter', 10, 2); /** * Function for `acf/is_field_key` filter-hook. * * @param bool $bool The result. * @param string $id The identifier. * * @return bool */ function wp_kama_acf_is_field_key_filter( $bool, $id ){ // Filter... return $bool; }
-
$bool
(true|false) - The result.
-
$id
(рядок) - Ідентифікатор.
список змін
З версії 5.7.10 | Введено. |
Де викликається хук
acf/is_field_key
acf/includes/acf-field-functions.php 197
return apply_filters( 'acf/is_field_key', false, $id );
Де використовується хук в Advanced Custom Fields
acf/includes/local-fields.php 546
add_filter( 'acf/is_field_key', '_acf_apply_is_local_field_key', 20, 2);