Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #1059485

    Does anyone know how to remove the “Edit Page (Advanced Layout Builder)” text, specifically the “(Advanced Layout Builder)” or “(Classic Editor)” text from the frontend view in the Admin Bar?

    The theme informing me what type of editor is to be called provides little value and takes up valuable admin bar space. Again, completely subjective but perhaps others will desire the same.

    Inspecting how I can hook into this code to alter it I see that it is being called from the “class-avia-gutenberg.php” file under config-gutenberg directory. But I do not know of a way to hook into the function to replace/eliminate it.

    Any help or guidance in this regard would be greatly appreciate.

    #1060573

    Hey Manny,

    Thank you for using enfold.

    I added a filter for the next update.

    Meanwhile please replace

    enfold\config-gutenberg\class-avia-gutenberg.php

    with

    https://github.com/KriesiMedia/enfold-library/blob/master/temp_fixes/Enfold_4_5_3/config-gutenberg/class-avia-gutenberg.php

    Then you can use a filter:

    
    add_filter( 'avf_gutenberg_admin_bar_edit_page_info', 'modify_admin_bar_edit_page_info', 10, 1 );
    function modify_admin_bar_edit_page_info( $show )
    {
    	$show = 'hide';
    	return $show;
    }
    

    Best regards,
    Günter

    #1060584

    And by the way – to get rid of this info in list view Pages / Posts in the backend – ad to functions.php of child-theme:

    add_filter('display_post_states','remove_ALB_post_state',999,2);
    function remove_ALB_post_state( $post_states, $post ) {
    	if("! has_blocks( $post->ID )") {
    		unset($post_states['wp_editor']);
    	}
    	if("!= Avia_Builder()->get_alb_builder_status($post->ID)") {
    		unset($post_states['avia_alb']);
    	}
    return $post_states;
    }
    #1060609

    Excellent work sir @Günter. Thank you kindly. MUCH BETTER!

    #1060610

    SWEET! Thank you for that helpful information @Guenni007. You have restored and simplified my post/page list view within the backend!

    #1060754

    Hi,

    Glad this issue is resolved!

    Please take a moment to review our theme and show your support https://themeforest.net/downloads
    Don’t forget to bookmark Enfold Documentation for future reference.

    Thank you for using Enfold :)

    Best regards,
    Vinay

Viewing 6 posts - 1 through 6 (of 6 total)
  • The topic ‘How to Remove Admin Bar Editor Type from Displaying – (Advanced Layout Builder)’ is closed to new replies.