wp_admin_css_color

SummerySummery

Registers an admin color scheme css file.

Syntax

wp_admin_css_color( string $key, string $name, string $url, array $colors = array(), array $icons = array() )

DescriptionDescription

Allows a plugin to register a new admin color scheme. For example:

wp_admin_css_color( 'classic', __( 'Classic' ), admin_url( "css/colors-classic.css" ), array(
    '#07273E', '#14568A', '#D54E21', '#2683AE'
) );

ParametersParameters

$key

(string) (Required) The unique key for this theme.

$name

(string) (Required) The name of the theme.

$url

(string) (Required) The URL of the CSS file containing the color scheme.

$colors

(array) (Optional) An array of CSS color definition strings which are used to give the user a feel for the theme.

Default value: array()

$icons

(array) (Optional) CSS color definitions used to color any SVG icons.

  • 'base'
    (string) SVG icon base color.
  • 'focus'
    (string) SVG icon color on focus.
  • 'current'
    (string) SVG icon color of current admin menu link.

Default value: array()

SourceSource

File: wp-includes/general-template.php


			

ChangelogChangelog

Changelog
Version Description
2.5.0 Introduced.
Scroll to Top