ACF_Local_JSON::update_internal_post_type
Writes ACF posts to the JSON file.
Метод класса: ACF_Local_JSON{}
Хуки из метода
Возвращает
true|false.
Использование
$ACF_Local_JSON = new ACF_Local_JSON(); $ACF_Local_JSON->update_internal_post_type( $post );
- $post(массив) (обязательный)
- The main ACF post array.
Список изменений
| С версии 6.1 | Введена. |
Код ACF_Local_JSON::update_internal_post_type() ACF Local JSON::update internal post type ACF 6.4.2
public function update_internal_post_type( $post ) {
if ( ! $this->is_enabled() ) {
return false;
}
/**
* Filters the ACF post before saving it to the file.
*
* @since 6.1
*
* @param array $post The main ACF post array
*/
$post = apply_filters( 'acf/pre_save_json_file', $post );
return $this->save_file( $post['key'], $post );
}