I m developing a wordpress theme for wordpress theme directory. In this theme, I have set a custom header image by this bellow at functions.php
$defaults = array(
'width' => 1600,
'height' => 400,
'flex-height' => false,
'flex-width' => false,
'default-image' => get_template_directory_uri() . '/images/lemon.jpg',
'uploads' => true,
'default-text-color' => '95b849',
'header-text' => true,
);
add_theme_support( 'custom-header',$defaults);
and I show this header image like bellow:
<div class="header_top_image" style="background-image: url(<?php header_image(); ?>); background-color: #<?php echo get_header_textcolor();?>;">
<h1 class="header_top_title">
<a style="color: #<?php echo get_header_textcolor();?>;" href="<?php echo esc_url( home_url( '/' ) ); ?>">
<?php bloginfo('name'); ?>
</a>
</h1>
</div>
In this situation, I want: if not set Custom Header image, This "header_top_image" class's div tag totally don't show.
How I can do that. Actually I thought, there is a function: is_custome_header() , even I search at codex. But not found any function like this which provide if condition. Any body can help me? I need very much this solution. Advance thanks