Changeset 20851 for trunk/wp-includes/class-wp-customize.php
- Timestamp:
- 05/23/2012 03:36:27 PM (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-includes/class-wp-customize.php
r20809 r20851 565 565 566 566 $this->add_setting( 'header_textcolor', array( 567 // @todo: replace with a new accept() setting method 568 // 'sanitize_callback' => 'sanitize_hexcolor', 567 'sanitize_callback' => 'sanitize_header_textcolor', 569 568 'theme_supports' => array( 'custom-header', 'header-text' ), 570 569 'default' => get_theme_support( 'custom-header', 'default-text-color' ), … … 794 793 }; 795 794 795 // Callback function for sanitizing the header textcolor setting. 796 function sanitize_header_textcolor( $color ) { 797 if ( empty( $color ) ) 798 return get_theme_support( 'custom-header', 'default-text-color' ); 799 800 elseif ( $color == 'blank' ) 801 return 'blank'; 802 803 return sanitize_hexcolor( $color ); 804 } 805 796 806 // Callback function for sanitizing a hex color 797 807 function sanitize_hexcolor( $color ) {
Note: See TracChangeset
for help on using the changeset viewer.