Skip to content

Instantly share code, notes, and snippets.

@nicomollet
Last active June 9, 2023 13:14
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save nicomollet/7fd3e2e5334ef352abe0 to your computer and use it in GitHub Desktop.
Save nicomollet/7fd3e2e5334ef352abe0 to your computer and use it in GitHub Desktop.
Wordpress Admin Color Scheme
<?php
// Generate an admin scheme using the generator here: http://themergency.com/generators/admin-color-scheme-generator/
// Copy the css file in css/admin.css
// Then include this function in your functions.php
// And setup the four hexadecimal colors
function custom_admin_color_schemes() {
$theme_dir = get_template_directory_uri();
wp_admin_css_color( 'nameofscheme', 'Name of Scheme',
$theme_dir . 'css/admin.css',
array( '#8e0c70', '#5f084b', '#e0feff', '#006F71' )
);
}
add_action('admin_init', 'custom_admin_color_schemes');
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment