Last active
June 10, 2021 13:53
-
-
Save jonbrockett/aa5da1fcc8ee805e9eb5312419b3281c to your computer and use it in GitHub Desktop.
ACF Option Pages
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* ACF Option Pages | |
*/ | |
if( function_exists('acf_add_options_page') ) { | |
acf_add_options_page(array( | |
'page_title' => 'Site Settings', | |
'menu_title' => 'Site Settings', | |
'menu_slug' => 'site-settings', | |
'capability' => 'edit_posts', | |
'redirect' => false | |
)); | |
acf_add_options_sub_page(array( | |
'page_title' => 'Header Settings', | |
'menu_title' => 'Header', | |
'parent_slug' => 'site-settings', | |
)); | |
acf_add_options_sub_page(array( | |
'page_title' => 'Footer Settings', | |
'menu_title' => 'Footer', | |
'parent_slug' => 'site-settings', | |
)); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** Add ACF Option Pages */ | |
require_once( 'library/acf-options.php' ); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment