'', 'default-text-color' => '555555', 'width' => 1600, 'height' => 200, 'flex-width' => true, 'flex-height' => true, 'header-text' => true, 'wp-head-callback' => 'xsbf_header_style', 'admin-head-callback' => 'xsbf_admin_header_style', 'admin-preview-callback' => 'xsbf_admin_header_image', ) ) ); } add_action( 'after_setup_theme', 'xsbf_custom_header_setup' ); endif; //end ! function_exists if ( ! function_exists( 'xsbf_header_style' ) ) : /** * Styles the header image and text displayed on the blog * * This function handles BOTH previewing in the customizer as well as the actual display * of the header in the front-end. This function ONLY needs to handle hiding or displaying * the site title and custom header text color. All other styles are from the front-end * CSS. * * @see xsbf_custom_header_setup(). */ function xsbf_header_style() { // get_header_textcolor() returns 'blank' if hiding site title and tagline or returns // any hex color value. HEADER_TEXTCOLOR is always the default color. $header_text_color = get_header_textcolor(); // If no custom options for text are set, let's bail if ( HEADER_TEXTCOLOR == $header_text_color AND ! display_header_text() ) { return; } // If we get this far, we have custom styles. Let's do this. ?> Header admin panel. * * This function is NOT used by the Customizer, just the stand-alone header upload screen. * Since the front-end CSS is not loaded in Admin, all the heading styles need to be * inlined here to match the front-end CSS, including the image, h1, and h2 styles. This * function does NOT need to handle hiding or displaying text as that is handled by core * WordPress. * * @see xsbf_custom_header_setup(). */ if ( ! function_exists( 'xsbf_admin_header_style' ) ) : function xsbf_admin_header_style() { $header_image = get_header_image(); ?> Header admin panel. * * This callback overrides the default markup displayed there. * * This needs to output the HTML that ties to the inline CSS above to style the custom * header image, site title, and tagline. * * @return void */ if ( ! function_exists( 'xsbf_admin_header_image' ) ) : function xsbf_admin_header_image() { ?>