Completely disable editor

Why not use custom post types and don’t add any support for the editor, that is afterall what they are for and the easiest way . The answer in this post covers how to do that,

Hide content box with Custom Post Type?
http://codex.wordpress.org/Function_Reference/register_post_type

To remove that functionality for pages or posts (and custom types) you can try and use remove_post_type_support . For pages;

add_action('init', 'my_remove_editor_from_post_type');
function my_remove_editor_from_post_type() {
    remove_post_type_support( 'page', 'editor' );
}

Ref: http://codex.wordpress.org/Function_Reference/remove_post_type_support

A hacky solution is to use CSS display:none; for the #editorcontainer or one of the sub id or classes. You can also then enqueue that style only for particular users.

Leave a Comment