Browse Source

editor styles

windhamdavid 5 months ago
parent
commit
a5020f8cc5
1 changed files with 7 additions and 1 deletions
  1. 7 1
      functions.php

+ 7 - 1
functions.php

@@ -5,6 +5,12 @@ function lnr24_enqueue_assets() {
 }
 add_action( 'wp_enqueue_scripts', 'lnr24_enqueue_assets' );
 
+function lnr24_theme_setup() {
+  add_theme_support( 'editor-styles' );
+  add_editor_style( 'style-editor.css' );
+}
+add_action( 'after_setup_theme', 'lnr24_theme_setup' );
+
 /***********************************************************
 ###################### BrowserSync #########################
 ************************************************************/
@@ -78,7 +84,7 @@ add_action( 'admin_menu', 'lnr24_remove_admin_pages', 99 );
 function lnr24_remove_admin_pages() {
   global $current_user;
   $user_id = get_current_user_id();
-  if($user_id != '1') {
+  if($user_id != '0') {
   	remove_menu_page('plugins.php');
     remove_menu_page('tools.php');
     remove_menu_page('options-general.php');