Created
June 11, 2018 20:17
-
-
Save Sanabria/3de6aad361a5e18b216d6a6940f56a06 to your computer and use it in GitHub Desktop.
include ACF into Sage 9
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
/** | |
* Customize ACF path | |
*/ | |
add_filter('acf/settings/path', function ( $path ) { | |
$path = get_stylesheet_directory() . '/../vendor/advanced-custom-fields/advanced-custom-fields-pro/'; | |
return $path; | |
}); | |
/** | |
* Customize ACF dir | |
*/ | |
add_filter('acf/settings/dir', function ( $dir ) { | |
$dir = get_stylesheet_directory_uri() . '/../vendor/advanced-custom-fields/advanced-custom-fields-pro/'; | |
return $dir; | |
}); | |
/** | |
* Hide ACF field group menu item | |
*/ | |
// add_filter('acf/settings/show_admin', '__return_false'); | |
/** | |
* include ACF | |
*/ | |
include_once( get_stylesheet_directory() . '/../vendor/advanced-custom-fields/advanced-custom-fields-pro/acf.php' ); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment