Coming very soon is the next major WordPress update 5.0. Unless you’ve have been hiding under a small bridge somewhere then you’ll probably know that this release comes with a brand new page edit called how to edit the functions.php file. This has had a lot of criticism with most people saying it’s just not ready, other still saying it has bugs but eventually it will replace the old TinyMCE editor for good.
Personally I think this is what the WordPress needs as for just adding text it’s fine but to add columns, tables or other design elements requires a plugin to generate shortcodes or an external page builder, some of which are fantastic, some of which are not!
Most current themes are not set up to accommodate Gutenberg so it may cause a lot issues. Luckily it can be disabled quite easily….
Disable Gutenberg using a plugin
This is the easiest solution simply install the Disable Gutenberg plugin and configure the options to work as you wish. Currently as of 20/11/2018 is offers the below options:
- Disable Gutenberg completely (all post types)
- Disable Gutenberg for any post type
- Disable Gutenberg for any user role
- NEW: Disable Gutenberg for any theme template
- NEW: Disable Gutenberg for any post/page IDs
- Disable Gutenberg admin notice (nag)
- Option to hide the plugin menu item
- Option to hide the Gutenberg plugin menu item (settings link)
- NEW! Adds WP menu item: “Add New (Classic)”
- NEW! Adds post link to “Edit (Classic)”
Disable Gutenberg without using a plugin
Plugins are fantastic and really expand WordPress but it is important to use as few as possible to ensure WordPress runs as quickly as possible so my view is it something can be done easily without using a plugin then that is a better option.
This option does require adding some code to your theme’s functions.php file so if you”re not sure what you’re doing or not comfortable then then option above is more suitable. If you’re happy adding code.
For Gutenberg 4.1 or Higher
Add the below line of code to your theme’s functions.php file. You can do this by downloading your theme files or it can be done using the WordPress editor this post will show you how to edit the functions.php file.
add_filter('use_block_editor_for_post', '__return_false');
For Gutenberg versions older that 4.1 and 5.0 beta or below
Add the below line of code to your theme’s functions.php file.
add_filter('gutenberg_can_edit_post_type', '__return_false');
A Disclaimer
WordPress and Gutenberg is constantly changing nad being updated so we will keep this post updated as best we can but please be sure to test the code before adding it to your live site where possible.