Home Forums General Issues ACF-JSON Custom Folder Location Not Working Reply To: ACF-JSON Custom Folder Location Not Working

  • Hey @blakemiller,

    You’re mixing up filters here. save_paths doesn’t support a type argument, as it’s for filtering the whole array, although we do pass you in the post as an argument so you can detect if it you like:

    apply_filters( 'acf/json/save_paths', $paths, $post );

    Alternatively, you can use the save_path (no s) setting with a type argument, so something like:

    add_filter( 'acf/settings/save_json/type=acf-post-type', 'set_custom_json_save_path_for_post_types' );
    function set_custom_json_save_path_for_post_types() {
    	return get_stylesheet_directory() . '/acf-json/post-types';

    We have to keep both around for backwards compatibility, so sorry it’s a bit confusing!