Support

Account

Home Forums Gutenberg Your site doesn’t include support for the "acf/block-name" block. Reply To: Your site doesn’t include support for the "acf/block-name" block.

  • Like this? (This is what I did on the three plugins I thought of that would be affected, and this seems to work).

    
    
    /////////////////
    // INCLUDE ACF //
    /////////////////
    
    // Define path and URL to the ACF plugin.
    define( 'ELODIN_SECTION_BLOCK_ACF_PATH', plugin_dir_path( __FILE__ ) . 'vendor/acf/' );
    define( 'ELODIN_SECTION_BLOCK_ACF_URL', plugin_dir_url( __FILE__ ) . 'vendor/acf/' );
    
    if( !class_exists('ACF') ) {
        
        // Include the ACF plugin.
        include_once( ELODIN_SECTION_BLOCK_ACF_PATH . 'acf.php' );
    
        // Customize the url setting to fix incorrect asset URLs.
        add_filter('acf/settings/url', 'elodin_sections_block_acf_settings_url');
        
    }
    
    function elodin_sections_block_acf_settings_url( $url ) {
        return ELODIN_SECTION_BLOCK_ACF_URL;
    }