ACF_UI_Options_Page::setup_local_json
Sets up the local JSON functionality for options pages.
Method of the class: ACF_UI_Options_Page{}
No Hooks.
Returns
null. Nothing (null).
Usage
$ACF_UI_Options_Page = new ACF_UI_Options_Page(); $ACF_UI_Options_Page->setup_local_json();
Changelog
| Since 6.2 | Introduced. |
ACF_UI_Options_Page::setup_local_json() ACF UI Options Page::setup local json code ACF 6.8.8
public function setup_local_json() {
$local_json = acf_get_instance( 'ACF_Local_JSON' );
// Event listeners.
add_action( 'acf/update_ui_options_page', array( $local_json, 'update_internal_post_type' ) );
add_action( 'acf/untrash_ui_options_page', array( $local_json, 'update_internal_post_type' ) );
add_action( 'acf/trash_ui_options_page', array( $local_json, 'delete_internal_post_type' ) );
add_action( 'acf/delete_ui_options_page', array( $local_json, 'delete_internal_post_type' ) );
}