acf_get_field_reference()
Устарела с версии 5.6.8. Больше не поддерживается и может быть удалена. Рекомендуется заменить эту функцию на аналог.
acf_get_field_reference
Finds the field key for a given field name and post_id.
Хуков нет.
Возвращает
Строку
. $reference The field key
Использование
acf_get_field_reference( $field_name, $post_id );
- $field_name(строка) (обязательный)
- The name of the field. eg 'sub_heading'
- $post_id(разное) (обязательный)
- The post_id of which the value is saved against
Список изменений
С версии 5.6.5 | Введена. |
Устарела с | 5.6.8 |
Код acf_get_field_reference() acf get field reference ACF 6.0.4
function acf_get_field_reference( $field_name, $post_id ) { // Warning. _deprecated_function( __FUNCTION__, '5.6.8', 'acf_get_reference()' ); // Return reference. return acf_get_reference( $field_name, $post_id ); }