Disable header banner on specific Posts

You can make the banner unavailable to certain posts by using if condition. $post_id = get_the_ID(); if ($post_id != idwheredisabled || $post_id != id2wheredisabled || …. ){ Adsense code } if there are many ids then you can load them into an array and check if exists in array.

How to make custom_header_setup() image as background image?

Because you have used it as an image. <img src=”https://…” height=”…” width=”…”/> This code is used to display images, not background images. Use it with text: <div style=”background-image: url(../images/test-background.gif); height: 200px; width: 400px; border: 1px solid black;”>Example of a DIV element with a background image:</div> Or without text: <div style=”background-image: url(../images/test-background.gif); height: 200px; width: 400px; … Read more

Embed Form In Header

You need to edit header.php of your theme and insert the script there right after the site navigation. I try to use the plugin for header & footer to paste the code & display but via plugin code working in the footer but in header nothing display. Plugins fail to insert this in header because … Read more

Where is the Javascript attribute window._wpCustomHeaderSettings defined?

It’s defined via wp_localize_script() that’s called by the_custom_header_markup(): wp_localize_script( ‘wp-custom-header’, ‘_wpCustomHeaderSettings’, get_header_video_settings() ); So if you want to override the values/settings using JavaScript, then you can hook to wp_print_footer_scripts and add your script like so: add_action( ‘wp_print_footer_scripts’, function(){ if ( wp_script_is( ‘wp-custom-header’ ) ) : ?> <script> if ( window._wpCustomHeaderSettings ) { _wpCustomHeaderSettings.minHeight = 0; … Read more

My custom header does not change the header image height and width

You have forgot to do “echo” the Height & Width in Image code. Your Header code should like below. <img src=”https://wordpress.stackexchange.com/questions/348195/<?php header_image(); ?>” height=”<?php echo get_custom_header()->height; ?>” width=”<?php echo get_custom_header()->width; ?>” alt=””> <?php wp_nav_menu( array(‘theme_location’ => ‘primary’) ); ?> check this reference https://codex.wordpress.org/Custom_Headers

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)