How do I get the page template name chosen?
I picked the following code from an answer here, https://stackoverflow.com/questions/2544870/remove-main-editor-from-wordpress-edit-page-screen/42093956. I tweaked the code to remove the classic editor on pages using default page template. And added the comments. function remove_editor_init() { $post_id = 0; if ( isset( $_GET[‘post’] ) ) { $post_id = $_GET[‘post’]; } $template_file = get_post_meta( $post_id, ‘_wp_page_template’, TRUE ); // var_dump($template_file) … Read more