ACF\Meta

Option::delete_valuepublicACF 6.4

Deletes a field value from the database.

Метод класса: Option{}

Хуков нет.

Возвращает

true|false.

Использование

$Option = new Option();
$Option->delete_value( $object_id, $field ): bool;
$object_id(int|строка)
The ID of the object the metadata is for.
$field(массив)
The field array.
По умолчанию: array()

Список изменений

С версии 6.4 Введена.

Код Option::delete_value() ACF 6.4.2

public function delete_value( $object_id = 0, array $field = array() ): bool {
	return delete_option( $object_id . '_' . $field['name'] );
}