Support » Plugin: Freesoul Deactivate Plugins: Plugin Manager » Deactivate plugins on Editor (Gutenberg)?

  • Resolved acon

    (@acon)


    Hi, I found FDP plugin super useful for increase load time of my website, especially the backend.

    I now know how to deactivate plugins in my Oxygen builder editor, but can I do the same for the normal WordPress Editor (Gutenberg) interface? i.e the page showing up when I hit Edit on a post list.

    I don’t know what URL to use to do this in FDP. I don’t even know if Gutenberg belongs to frontend (like Oxygen) or backend to be honest…

    I’ll appreciate if anyone can lighten my way here. Cheers.

Viewing 7 replies - 1 through 7 (of 7 total)
  • Plugin Author Jose

    (@giuse)

    Hi @acon

    I’m happy you find it useful. I hope to decrease the loading time, not increase 🙂

    To disable plugins when you edit a page (with or without Gutenberg) you can use the options that you find in Freesoul Deactivate Plugins => Backend => Backend URLs.

    Use this pattern: *wp-admin/post.php?post=*&action=edit*

    I hope it helps.

    Thread Starter acon

    (@acon)

    Hi Jose @giuse ,

    Thanks so much!! It works like a charm.

    I hope you can keep developing this fantastic plugin. I will definitely pay if you release a pro version with more features!

    Regards,
    Acon

    Plugin Author Jose

    (@giuse)

    Hi @acon
    many thanks to you! I’m happy it works.
    I’m working on the PRO version. I hope it will be ready soon.

    Hello @giuse

    First I have to say that I have dreamed of this plugin for so long so thank you for make it happen !

    I have followed the idea of this topic but I’m wondering if there is a possible way to filter the post-type in back-end ?

    Actually, there is no parameter or something else in the url so I can’t make a difference, or I have to put manually all the post ID. Problem : there are more than 200 ids at the moment and it is growing.

    I had the idea to use a general filter as post=*
    and then another more specific with as idea as post=13

    But we have no hand on the priority so it doesn’t work.

    Any ideas to share ? Thanks

    Plugin Author Jose

    (@giuse)

    Hi @khobs

    thank you very much!

    I think it would be better if the core added a parameter to the editing link for saying the post type. It would be useful also in other cases.

    In any case, you can add it yourself.

    If you have a child theme or a function plugin, add these lines of code:

    add_filter( 'get_edit_post_link','my_edit_post_link',10,3 );
    function my_edit_post_link( $link,$post_id,$context ){
    	$post_type = get_post_type( $post_id );
    	if( $post_type ){
    		return add_query_arg( 'post_type',$post_type,$link );
    	}
    	return $link;
    }

    Then when you click on an edit link of a page you should see something that looks like: https://sample-domain.com/wp-admin/post.php?post=3121&action=edit&post_type=page and similar links for other post types.

    Then in the Backend URLs settings, you can use e.g. *wp-admin/post.php?post=*&action=edit&post_type=page* for the pages, or in general

    *wp-admin/post.php?post=*&action=edit&post_type=post-type-name* where post-type-name is the name of the post type.

    This will work after you refresh the backend and you click on an edit link. If you already have an editing screen open, it will not work.

    I hope it helps.

    OMG *_* Thank you so much @giuse !

    I’ve thought about this but I was not able to do it on code. I was just manually doing it with some : j=j / p=p and trying to remember what is what.

    This is life changer, thank you !!!

    Plugin Author Jose

    (@giuse)

    You are welcome @khobs ! I’m happy that it was helpful.

Viewing 7 replies - 1 through 7 (of 7 total)
  • You must be logged in to reply to this topic.