* * @link https://developer.wordpress.org/themes/functionality/custom-headers/ * * @package BroadNews */ /** * Set up the WordPress core custom header feature. * * @uses broadnews_header_style() */ function broadnews_custom_header_setup() { add_theme_support('custom-header', apply_filters('broadnews_custom_header_args', array( 'default-image' => get_stylesheet_directory_uri() . '/assets/img/default-header-image.jpg', 'default-text-color' => 'ffffff', 'width' => 1500, 'height' => 400, 'flex-height' => true, 'wp-head-callback' => 'broadnews_header_style', ))); } add_action('after_setup_theme', 'broadnews_custom_header_setup'); if (!function_exists('broadnews_header_style')) : /** * Styles the header image and text displayed on the blog. * * @see broadnews_custom_header_setup(). */ function broadnews_header_style() { $broadnews_header_image_tint_overlay = broadnews_get_option('enable_header_image_tint_overlay'); $broadnews_site_title_font_size = broadnews_get_option('site_title_font_size'); $broadnews_header_textcolor_dark_mode = broadnews_get_option('header_textcolor_dark_mode'); $broadnews_header_text_color = get_header_textcolor(); // If we get this far, we have custom styles. Let's do this. ?>