Removing the TinyMCE editor for a given page template
You can try to hook on load-page hook instead of admin_init. It is supposed to be called only when a page is being edited, and then you should be able to use the global $post variable function hide_editor() { global $post; $template_file = get_post_meta($post->ID, ‘_wp_page_template’, true); if($template_file == ‘page-home.php’){ // template name here remove_post_type_support(‘page’, ‘editor’); … Read more