Hey Guys,
I hope you can help me. I want to create a header on top of the theme.
Like this: https://www.dropbox.com/s/briz0rbuds7zvnv/bildschirmfoto-2014-12-16-um-13.37.34_1024.png?dl=0
I added a customer header function to my function.php already (http://codex.wordpress.org/Custom_Headers)
$args = array( 'width' => 980, 'height' => 60, 'default-image' => get_template_directory_uri() . '/images/header.jpg', ); add_theme_support( 'custom-header', $args );
Then I can add a custom header like here
https://www.dropbox.com/s/5cpeis2sc4elh5w/Screenshot%202014-12-17%2020.58.11.png?dl=0
But in the end the header is not shown. Can anyone help me? Do I need to modify the Header.php? If yes how?
Thank you ! Really appreciate your help. I love your theme!
Cheers,
Christian
Hey there :D, you got the header but you just not show it out
But in the end the header is not shown. Can anyone help me? Do I need to modify the Header.php? If yes how?Yes !! you need to show the custom header in header.php
Like this :
<img src="<?php header_image(); ?>" height="<?php echo get_custom_header()->height; ?>" width="<?php echo get_custom_header()->width; ?>" alt="" />Place that code at where you want your header to appear
![]()
BTW , when i use this code , there 's some css class at my page brake , so you should have a <div> class wrap that header
And use flexible header to crop the header image
Please refer the answer of @nobita provided. If you still face there issue, please let us know.
Regards,
Please login or Register to submit your answer