HEX
Server: nginx/1.27.1
System: Linux in-4 5.15.0-131-generic #141-Ubuntu SMP Fri Jan 10 21:18:28 UTC 2025 x86_64
User: ilikadirect (1186)
PHP: 7.4.33
Disabled: exec,passthru,shell_exec,system,proc_open,popen,parse_ini_file,show_source
Upload Files
File: /storage/v6964/iskcon/public_html/wp-content/themes/spiritual-meditation/inc/custom-header.php
<?php
/**
 * Custom header implementation
 */

function spiritual_meditation_custom_header_setup() {
	add_theme_support( 'custom-header', apply_filters( 'spiritual_meditation_custom_header_args', array(
		'default-text-color' => 'fff',
		'header-text' 	     =>	false,
		'width'              => 1200,
		'height'             => 90,
		'flex-width'         => true,
		'flex-height'        => true,
		'wp-head-callback'   => 'spiritual_meditation_header_style',
	) ) );
}

add_action( 'after_setup_theme', 'spiritual_meditation_custom_header_setup' );

if ( ! function_exists( 'spiritual_meditation_header_style' ) ) :
/**
 * Styles the header image and text displayed on the blog
 *
 * @see spiritual_meditation_custom_header_setup().
 */
add_action( 'wp_enqueue_scripts', 'spiritual_meditation_header_style' );
function spiritual_meditation_header_style() {
	//Check if user has defined any header image.
	if ( get_header_image() ) :
	$custom_css = "
        .main-header {
			background-image:url('".esc_url(get_header_image())."');
			background-position: bottom center;
			background-size: 100% 100%;
		}";
   	wp_add_inline_style( 'spiritual-meditation-basic-style', $custom_css );
	endif;
}
endif; // spiritual_meditation_header_style