• Skip to primary navigation
  • Skip to main content
  • Skip to primary sidebar
  • Skip to footer
WordPress a2z

WordPress a2z

WordPress Dynamic API Reference

  • Home
  • Plugins
  • Themes
  • Shortcodes
  • APIs
  • Classes
  • Files
  • Hooks
  • Sitemap
  • Blog
Home / APIs / twentysixteen_get_color_scheme() – Retrieves the current Twenty Sixteen color scheme.

You appear to be a bot. Output may be restricted

Description

Retrieves the current Twenty Sixteen color scheme.

Create your own twentysixteen_get_color_scheme() function to override in a child theme.

Usage

$array = twentysixteen_get_color_scheme();

Parameters

Returns

array An associative array of either the current or default color scheme HEX values.

Source

File name: twentysixteen/inc/customizer.php
Lines:

1 to 10 of 10
  function twentysixteen_get_color_scheme() {
    $color_scheme_option = get_theme_mod( 'color_scheme', 'default' );
    $color_schemes       = twentysixteen_get_color_schemes();

    if ( array_key_exists( $color_scheme_option, $color_schemes ) ) {
      return $color_schemes[ $color_scheme_option ]['colors'];
    }

    return $color_schemes['default']['colors'];
  }
 

 View on Trac

Published: 25th November 2019 | Last updated: 25th November 2019

Primary Sidebar

Information

Function name: twentysixteen_get_color_scheme
Plugin ref: Twenty Sixteen
Version: 2.8
Sourcefile: inc/customizer.php
File ref: inc/customizer.php
Deprecated?: No
API Letters: C,G,S,T

Footer

WordPress a2z
WordPress a2z
WordPress Dynamic API Reference
WordPress 6.1.1. PHP: 8.0.28
WordPress a2z
WordPress core a2z
Genesis Theme Framework a2z
Jetpack a2z
WordPress develop tests
Easy Digital Downloads a2z
WooCommerce a2z
Yoast SEO a2z
WordPress Blocks

Site:  wp-a2z.org
© Copyright WordPress a2z 2014-2023. All rights reserved.


Website designed and developed by Herb Miller
Proudly powered by WordPress and oik plugins

  • Home
  • Blog
  • Sitemap
  • Sites