Use the_header_image_tag() function.
This commit is contained in:
parent
31a9e90437
commit
2370c59676
1 changed files with 1 additions and 3 deletions
|
@ -4,9 +4,7 @@
|
|||
*
|
||||
* You can add an optional custom header image to header.php like so ...
|
||||
*
|
||||
<?php if ( get_header_image() ) : ?>
|
||||
<img src="<?php header_image(); ?>" width="<?php echo esc_attr( get_custom_header()->width ); ?>" height="<?php echo esc_attr( get_custom_header()->height ); ?>" alt="">
|
||||
<?php endif; // End header image check. ?>
|
||||
<?php the_header_image_tag(); ?>
|
||||
*
|
||||
* @link https://developer.wordpress.org/themes/functionality/custom-headers/
|
||||
*
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue