Customize Lifestyle Pro Theme Header Image Area

In this tutorial, we’ll start with the default header and end up with a full width header image.

Update: Here’s a better solution tested on the latest version of Lifestyle Pro Responsive Full Header Image

Here’s the default header area of the Lifestyle Pro theme by StudioPress:

default header

And here’s what a full width header image looks like:

full width header image

The first step is to find this code in your child themes functions.php file and change the values for the width and height.

//* Add support for custom header
add_theme_support( 'custom-header', array(
	'header_image'    => '',
	'header-selector' => '.site-title a',
	'header-text'     => false,
	'height'          => 200,
	'width'           => 1140,
) );

In this example we’ll be using an image which is 1140px width by 200px height so the custom header settings need to match these dimensions.

Next step is to go to Appearance > Header and upload your header image using the Custom Header feature.

custom header

Here’s an example of what your header area may look like now:

new header image

The reason your header image isn’t filling up the entire header container is because there’s some CSS code adding a fairly hefty amount of padding on all 4 sides.

Reduce the padding to zero in the following CSS rule on line 1078.

.site-header {
	background-color: #27968b;
	padding: 0;
	overflow: hidden;
}

And here’s the result:

remove site header padding

The value for the height in the default CSS code needs increasing so you can modify the default CSS rule as follows on line 1142 so the min-height matches your image.

.header-image .site-title a {
	background-size: contain !important;
	float: none;
	min-height: 200px;
	width: 100%;
}

And here’s the result now:

increased header height

You may want to change the background color of the secondary nav menu so here’s some basic sample code you can modify to your own liking:

.genesis-nav-menu {
    clear: both;
	background-color: white;
	color: #333;
}

Here’s the final result which you should be happy with otherwise do let me know in the comments if its not exactly what you wanted.

background nav menu

Different Background Colors

Changing the background color of your header is easy. Simply add this code to the end of your child themes style.css file:

.lifestyle-pro-blue .site-header {
    background-color: #fff;
}

This code works if you have selected the green color style from the Genesis > Theme Settings > Color Style.

Color Style

You will need to change the first class in this rule to match the color you have selected from the above settings.

Example: If you’ve chosen green, your code would look like this:

.lifestyle-pro-green .site-header {
    background-color: #fff;
}

Otherwise, simply use this for the default:

.site-header {
    background-color: #fff;
}

And this if you get stuck as a last resort:

.site-header {
    background-color: #fff!important;
}

Change Font Color After Change Background

You will also need to change the font color for the secondary nav menu if your change the background color because the color is white by default:

.nav-secondary {
    	background-color: white;
}

.lifestyle-pro-red .archive-pagination li a,
.lifestyle-pro-red .genesis-nav-menu .current-menu-item > a,
.lifestyle-pro-red .genesis-nav-menu .sub-menu a,
.lifestyle-pro-red .nav-secondary a {
	color: #a5a5a3;
}

Header Right Widget

Note: You may now have problems with the header right widget because the entire width is now filled with your image. This can be solved by using a more flexible method.

Mobile Responsive Solution

Is your image cutoff or not displaying correctly on smaller screen widths?

Click here to use one solution which shows you how to easily add different images which display on different screen widths.


Comments

141 responses to “Customize Lifestyle Pro Theme Header Image Area”

  1. Brad Dalton Avatar
    Brad Dalton

    Update: Here’s a better solution tested on the latest version of Lifestyle Pro https://wpsites.net/web-design/lifestyle-pro-responsive-full-header-image/

  2. Help , please! I appreciate very much this tutorial, however, still teniendio a problem that is driving me crazy 🙁 On the web the header has been perfect , but mobile is very small and the Ipad is cut how to fix it? I do not know what to do 🙁

    The measures of the header are 1140×400

    Thank you !

    Elena M.

    1. Brad Dalton Avatar
      Brad Dalton

      Members only

  3. Donna Mavromates Avatar
    Donna Mavromates

    Hi Brad,

    Great tutorial! The only issue I’m having seems to be with the padding. I can’t seem to remove the white space above the header and also between the header and the secondary nav. This is what I have done regarding adding code:

    Changed this in the functions php:

    Many thanks for any assistance you can provide!

    Donna

    1. Brad Dalton Avatar
      Brad Dalton

      Please paste you code in a Github Gist and link to it from your comment.

      1. Hi Brad,

        I never used Github Gist before. I hope I did this correctly! I would like to remove the padding above and below the header and also have the header and navigation extend to the edges of the container.

        https://gist.github.com/25582672342b9f8f363a.git

        Donna

  4. Joel Jones Avatar
    Joel Jones

    I am using the Beautiful Pro child theme. It looks like the steps change the size to 1140 x 200, but I would like the box to be 1140 x 400.
    When I adjust the height in the php and the css file, nothing happens.
    Any way you could help me out here?
    Thanks

    1. Brad Dalton Avatar
      Brad Dalton

      Re upload the image and make sure you have changed all values for the height and width under the Site Header section to match the size of your new header.

      Also clear and server side, plugin and/or browser caching.

  5. Joel Jones Avatar
    Joel Jones

    I am using the Beautiful Pro child theme. It looks like the steps change the size to 1140 x 200, but I would like the box to be 2240 x 400.
    When I adjust the height in the php and the css file, nothing happens.
    Any way you could help me out here?
    Thanks

    1. Brad Dalton Avatar
      Brad Dalton

      Hi Joel

      There maybe more than one value for the hieght and width in the CSS you need to change under the Site Header section

      1. Joel Jones Avatar
        Joel Jones

        I am using the Beautiful Pro child theme. It looks like the steps change the size to 1140 x 200, but I would like the box to be 1140 x 400.
        When I adjust the height in the php and the css file, nothing happens.
        Any way you could help me out here?
        Thanks

        Thanks, I did find another place.
        You are very kind and generous.

        1. Brad Dalton Avatar
          Brad Dalton

          You will need to check your code and make sure all the values for the height have been changed to 400px.

  6. Steven Edward Avatar
    Steven Edward

    Brad-
    …And the Pulitzer goes to you! I simply retraced my steps, and everything worked! For the benefit of those who still have issues:
    #1- Get Rid of The Header Widget.
    #2- Make sure the CSS Snippet is the one indicating’100%, min height= 200 pixels.
    And you’re good to go.
    All the best,

    Steve

    1. Brad Dalton Avatar
      Brad Dalton

      Good stuff Steve!

  7. Steven Edward Avatar
    Steven Edward

    Hi Brad-

    I know you must be ‘swamped’ with response, judging by the number of ‘happy campers’ who’ve gotten this well-presented formula to work.
    I did all the numbers in the functions php, (though I just added the code at first); I found the other entry and adjusted the respective values, The header looks brilliant on the dashboard, but…nothing shows on the page except like 10% on the left-hand side. Also 200 looks like 25 pixels too short.
    I was really looking forward to seeing this work. Thanks in advance for any suggestions.
    Steve

    1. Brad Dalton Avatar
      Brad Dalton

      Appreciate the kind words Steven.

      I would need to inspect your code to fix the problem.

      Please use the contact form if you want me to fix it for you.

  8. Carmelo Avatar

    When I add a 1140X200 image wordpress delete borders of my image. I try to set a 960X200 image but the code not working 🙁 WordPress automatically take the class .header-full-width.header-image.site-title a. Can you help me please ? sorry for my bad english .

  9. Geremy Avatar

    Brad,

    I’ve followed your directions three times and still my 1140X200 picture won’t fit. I’ve even made the pic smaller and it still wont’t fit. Any suggestions?

    Thanks!

    1. Brad Dalton Avatar
      Brad Dalton

      Please link to your site Geremy.

      There are 2 changes you need to make to add a header image in any theme.

      The values for the width and height in the PHP code for the Custom Header function need to match the values for the width and height in the CSS under the Site Header section of your child themes style.css file.

      ALL values for width and height under the Site Header section need to be modified to match your header image size.

  10. Brad,
    Thanks for putting this up there. I purchased the Lifestyle theme to replace two sites I have with Prose and the only thing stopping me from making the change was the header. I had someone design a really nice header image and I didn’t want to stop using it.
    I’ll be back if I have any problems!

  11. Lixation Avatar

    Hi Brad,

    Just starting with Genesis and your blog has been a great help. Thank you.

    I wondered if you could help me on a few things:

    1. Can you tell me how to make the secondary navigation menu text bigger?

    2. How to get rid of the margin at the top of the page?

    3. How do you reduce the white space around the edge of the theme?

    Also, WordPress 3.9 seems to be over-riding any theme background change I make. It loads the color and then instantly swaps it for the default color instead. Do you have any idea about this?

    I really appreciate any help you can give me.

    Thanks

    1. Brad Dalton Avatar
      Brad Dalton

      $100 is my quote Peter.

      1. Chris Avatar

        Better charge more…I have a feeling he’s one of those “Just one more thing and we’re done” types…

        1. Lixation Avatar
          Lixation

          Not opposed to paying at all; just trying to learn some more CSS so I can edit my sites on the fly and not have to wait for a developer all the time. Happy to share my tips and strategy on my areas of expertise too. Thanks.

          1. Brad Dalton Avatar
            Brad Dalton

            Happy to help Lixation. Simply let me know what you want to learn.

  12. Hi Brad,

    Thank you for the post! I’m completely new to blogging, bought the Lifestyle Pro theme a few weeks ago and been struggling with a custom header till I read your post!

    The only problem I have is that after uploading the custom header (which in my case is a logo and a text), every time I refresh the website (if you can call it that as there’s nothing there yet) I get different results. Sometimes the header looks just the way I designed it but often it gets stretched out and my font and a logo get out of the frame.

    Could you help?

    Thank you

    1. Brad Dalton Avatar
      Brad Dalton

      Hello Aaron

      Make sure the dimensions the PHP code and CSS match the size of your image.

  13. Just bought Lifestyle Pro theme. Really new to editing in stylesheet. But, I’m always trying to be superwoman. Learned a little bit here and there with trial and error from blogging for almost 2 years. One question: If I’m trying to put social media icons in the header (which I have tried using coding in the stylesheet), do I need to increase the size of the header because after I put them there, it now makes my title jam to the left? Determined to get this editing the stylesheet conquered! If I succeed in doing this, then putting an image there will hopefully be easier.

    1. Brad Dalton Avatar
      Brad Dalton

      You can change the width of both the title area and header right widget in the header section of your style sheet so they both add up to the width of of header.

  14. If I could give you a hug, I would! I was getting ready to pay money to hire someone to fix my header for me, but this did the trick! Thank you!!!

    1. Brad Dalton Avatar
      Brad Dalton

      hahaha Thanks Lisa.

      I like it when people solve problems using my solutions but on the other hand understand i probably miss out some work as well by offering free solutions.

      Cheers

  15. David Perata Avatar
    David Perata

    I’ve been giving it another go. I followed your advice for the header but I can’t get rid of the padding, even after changing the values to “O”.

    It’s almost as if the CSS editor isn’t taking the changes.

    When I use Inspect Element on the header and make some changes on the right side CSS box, I can see the changes I need to make. It works.

    But when the very same code changes are in fact in the CSS editor, it won’t make that same change.

    1. Brad Dalton Avatar
      Brad Dalton

      Change the original values in the style.css file.

      You may also need to delete your caching if using a plugin or server caching.

  16. David Perata Avatar
    David Perata

    By the way, my first time around was with another fella’s advice, not yours.

    David

  17. David Perata Avatar
    David Perata

    Great info! Thanks!

    This is my second time around trying to get the header area of the Lifestyle Pro theme working like I wish.

    So, I started with a fresh InstantWP and Child Theme and what I get from “Visit Site” is a header with no navigation bars whatsoever.

    This is what happened the last time I tried.

    I started with the navigation bars intact, but after getting the header width and height where I wanted and my custom header image uploaded, I knocked out the navigation.

    I thought a fresh version would bring the navigation back.

    I’m not even sure if I want both navigation bars (top and under header) but I need to know how to get them back.

    I was told to go to Appearance/Menus/Navigation but on “Edit” comes up when I try that.

    Any ideas?

    Thanks.

    David Perata

    1. Brad Dalton Avatar
      Brad Dalton

      Would love to help David but without inspecting all the code its very difficult to fix localized issues.

      I would use the Custom Header uploader to add the image, modify the width and height in the functions file and then play around with the CSS for the Header Section to fix the padding, margins etc.

      I know its abit of work and depends on the size of your image.

      The Media Queries also require some tweaking.

      Good luck.

  18. Hi Brad,

    I’m wondering if it is possible to use the Genesis responsive slider in the header section of Lifestyle Pro.

    Thanks!

    1. Brad Dalton Avatar
      Brad Dalton

      Sure but easier and more efficient to hook in Soliloquy using the plugins template tag.

  19. clive bunch Avatar
    clive bunch

    Hi Brad, thanks for all your work I have learned a lot here.
    My question, I am using Studiopress Lifestyle Pro theme and want to use a header image. I can do that no problem with your tutorial but would like to use a site title also, I.E. superimposed over the image.
    Is this possible?
    Thanks in advance.

    1. Brad Dalton Avatar
      Brad Dalton

      You need to add header-text to your code like this:

      1. Thanks for sharing! I got the sizing of the header to work correctly, but when I uploaded my image, it completed changed the colors. Suggestions?

  20. Found the section here:
    [code]
    .header-image .title-area {
    padding: 0;
    }

    .header-image .site-title a {
    float: left;
    min-height: 200px;
    width: 100%;
    }
    [/code]

    Now the problem is the header width is cut off – not showing all of the header

    Any solutions?

    Thanks again

  21. Sorry to repeat the question asked by many, but I still don’t get it

    Is this the way to handle the CSS code, because for me it doesn’t work.

    I still get the thin looking header (see hhttp://vanakkamfoundation.org)

    Here’s where I placed the two pieces of code:
    [code]
    .site-header {
    background-color: #76d2c5;
    padding: 0px;
    padding: 0rem;
    overflow: hidden;
    }

    .header-image .site-title a {
    float: left;
    min-height: 200px;
    width: 100%;
    }
    [/code]
    or does the second part go some where else?

    Thanks

  22. Thanks Brad! Very helpful.

    1. Brad Dalton Avatar
      Brad Dalton

      You’re welcome Shelley.

  23. T. Johnson Avatar

    Very helpful thanks

  24. Jenin Kisna Avatar
    Jenin Kisna

    Thanks a bunch for this! Really helpful. Keep up the great work.

  25. Christine Avatar

    This was exactly what I was looking for, and worked perfectly, thank you!

  26. Hi Brad,

    I followed the directions you have here for customizing the header image and it worked great for awhile. Now I am having issues with what looks like the header widget. You did indicate that might be an issue. Would you be able to advise me on how to fix it?

    Thanks so much.

    1. Brad Dalton Avatar
      Brad Dalton

      Hello Sheila

      You would need to find another solution which doesn’t effect the header right widget area.

      1. Bummer. Ok, thanks.

        1. Brad Dalton Avatar
          Brad Dalton

          I have written other posts about this topic but you can never cover all bases.

  27. Everything looked great with my header until I used the secondary menu and then I got the huge padding(?) above it (below my header). Any clue what I could have done wrong or what this is all about?

    1. Brad Dalton Avatar
      Brad Dalton

      Hello Mary

      The method you used to add it may have caused that problem.

      1. You should use the Custom Header feature under Appearance > Header or, if your theme includes support for:
      2. Upload the image to your child themes images folder and name your header logo.png. ( Not all themes include the CSS code to support this method ) Lifestyle Pro doesn’t support this method however some other themes do.

      1. I did add the header using the custom header feature and I am using the Lifestyle Pro theme. So weird!!

        1. Brad Dalton Avatar
          Brad Dalton

          Using Firebug, your CSS code shows that the header image has been added using CSS code.

          I would find the code for this and remove it as this may be causing the problem.

  28. Hi, I tried this part:

    The value for the height in the default CSS code needs increasing so you can paste this code in after the first block which increases the value to 200px.
    [code]
    .header-image .site-title a {
    float: left;
    min-height: 200px;
    width: 100%;
    }
    [/code]
    I entered it after the first block (the site.header code) and it isn’t working?!

    Thanks for the tutorial by the way.

    1. Brad Dalton Avatar
      Brad Dalton

      Hello Stephen.

      Works perfectly for me.

      You must have missed something.

  29. Terri Voltz Avatar
    Terri Voltz

    Brad,
    Your article on adjusting the header was very helpful.

    Can you please help me find the post you added to the forum regarding the adjusting the header in media queries that you added on October 21, 2013? I have looked but cannot find it.

    I need to adjust the header so it displays correctly on a cell phone. Currently, the header shrinks and there is a very large border around the header.

    Here is your reply from Oct 22nd: “I answered this yesterday on the Sp forums with all the code i modified for the Media Queries so that the background color is removed when the screen is re-sized.”

    Thanks for your help.

    1. Brad Dalton Avatar
      Brad Dalton

      Terri

      Firebug will help you find the classes so you can modify the border at different screen sizes.

  30. Demon Warlock Avatar
    Demon Warlock

    Thank a lot.This is very great post

  31. Thank you Brad!

    Followed exactly as you said for header image change and worked no worries. Was having all sorts of resizing problems / cropping prior to finding your post….and….I’m not a developer or coder, so anyone can do this provided they read your instructions through first.

    To Abundance!

    Eileen.

  32. Curt Donohue Avatar
    Curt Donohue

    Thanks Brad. This was exactly what I was looking for.

  33. Hi Brad,

    I’m sooo glad to have found your site! I’m using the Lifestyle Pro Theme. I’ve had a hard time trying to have a header with text & a logo, and for it to adjust properly on an iPad. Finally, after reading your posts which are so helpful, I’m getting somewhere.

    My site & header looks exactly like I want it to on an iPad in landscape mode. (When viewing it in portrait mode, the sidebar gets moved to the bottom. This also happened from the very beginning, even before making any changes to the stlyesheet. I’m working on trying to fix one problem at a time.)

    After making the changes though, there is no padding when viewing the site on a laptop. I’m not sure how to fix this.

    My site is: http://www.personaldevelopmentcorner.com

    Thank you.

    1. Edit…

      I just viewed my site again and what happens when viewing on a laptop is that the sidebar goes to the bottom, not that there is no padding.

      1. Brad Dalton Avatar
        Brad Dalton

        Hello Dina

        You’ll need to modify the values for the padding at different screen sizes until you get it the way you want.

        1. OK Brad, Thanks.

          If I understand correctly…

          For example, I change the following code (and the rest like this) the 1139px and the
          max-width: 960px until it is fixed?
          [code]
          @media only screen and (max-width: 1139px) {

          .footer-widgets,
          .site-container,
          .wrap {
          max-width: 960px;
          }
          [/code]
          Sorry if this is a stupid question. I don’t really know what I’m doing, but I’m going to try it.

          [If I view the site with Explorer it’s fine. The problem is when I view it with Chrome]

          1. Brad Dalton Avatar
            Brad Dalton

            You can change the max-width value or add different declarations to existing Media Queries for the padding and margins etc.

          2. Did that.

            When I view the site in Chrome, Firefox, and in Landscape mode on the iPad it all works great!

            When I open the site in Explorer the sidebar is where it’s supposed to be, only problem is that there is too much space between the body & the sidebar.

            On the iPad, in portrait mode it still moves the sidebar at the bottom…

            I’ll be working on fixing these.

            Thank you so much for all your help. I really appreciate it.

  34. I have done and followed every step in resizing the header image and I have not been successful. You talk about the padding, and you say paste a code after the first block, I am not getting that.

    I am not a coder so there are some steps you probably think I am aware of. I have cleared my browser and I am still unsuccessful.

    Malia

    1. Brad Dalton Avatar
      Brad Dalton

      Custom responsive coding is not included in this tutorial because different people use different sized images so the code will be different for everyone.

  35. Thank you so much for this wonderful tutorial. I have had success, except my header – size is 1140 x 187 – is being cut off on the left and right side. I have double and triple checked the size is 1140 Wide. Any suggestions.

    Here is the site http://www.travellingfortwo.com

    Thanks! Julie

    1. Brad Dalton Avatar
      Brad Dalton

      Hi Julie

      I do apologize as the header needs to be smaller than 1140px which is the actual width of the site container and the image doesn’t extend the full width of the site container.

      I haven’t actually worked out the correct width as there’s padding that needs to be subtracted from that figure.

      You could add it using CSS like this:
      [code]
      .site-header {
      background-image: url(images/header.png);
      }
      [/code]

      You could also try adding a width and height to the CSS:

      [code]
      .site-header {
      background-image: url(images/header.png);
      width: 1140px;
      height: 200px;
      }
      [/code]

      1. Thanks so much, I will fiddle with the sizes! A few questions:

        1 do you know where I would change the white background to a cream colour.
        2. could I put negative value for the header size and have the header extend right to my background so I don’t have that white boarder?
        3 what program do you use to view the WP style.css – I wish they had a search button in that area!

        1. Brad Dalton Avatar
          Brad Dalton

          Use Firebug or Chrome to inspect the elements you want to customize or open your style sheet busing Notepad++ and go to the header section where you’ll find all the code for the .site-header

  36. Thank you for this great tutorial. i just have a couple questions:

    How do I change the color links on the navigation bar, especially the secondary bar? I would like them to stay a visible color? I know it is likely VERY easy to fix, but thought I would ask.

    Thanks again!

    1. Brad Dalton Avatar
      Brad Dalton

      Try this http://wpsites.net/web-design/changing-the-primary-navigation-colors-in-studiopress-themes/

      You will need to use Firebug or Chrome dev tools to find the right nav menu classes.

  37. Katie Clark Avatar
    Katie Clark

    Hi Brad —

    I tried to follow this tutorial completely, but I’m still not seeing the results I want. It seems as if there’s a big white space all around the header still, that’s cutting off the parts of my header.

    I also tried using your tutorial on removing padding, but that didn’t seem to work either. I’ve gone through this tutorial several times and can’t see what I’m doing wrong.

    Thanks!

    1. Brad Dalton Avatar
      Brad Dalton

      Hello Katie

      Just published a post on how to remove the padding from around the header which may help. Its pretty simple.http://wpsites.net/web-design/remove-padding-from-lifestyle-pro-site-header/

      1. Katie Clark Avatar
        Katie Clark

        I tried that tutorial as well, and it still isn’t removed. I hate that I have to keep asking for help, but I’ve gone through this tutorial (and the other) several times and it’s not budging.

  38. yucatecha Avatar

    Thanks, Brad- very very helpful! (And really well written:))

    1. Brad Dalton Avatar
      Brad Dalton

      Thanks for the kind words Ann.

      I know a lot of people need help with customizing the header in this theme and hope it has helped somewhat.

      Hard to cover every different situation.

  39. Hi Brad,

    I have a quick question, i have modified my header image no problem to be full width but when i make the page smaller and the header shrinks to accompany it, i get alot of white space above and below the header.

    I even deleted the @media section to see if that’s where i went wrong but it makes no difference. I am just testing out the template at the moment feel free to take a look and shrink it down to a different window size so you can see what i am reffering too, it’s driving me insane! lol

    http://glamlady.shinymagic.com/

    Thanks, Lynsey

    1. Brad Dalton Avatar
      Brad Dalton

      Hello Lynsey

      You can remove all the padding and margins using Media Queries.

      Inspect the white space using Firebug, find the classes and then add then to your Media queries with values that remove the padding and margins.

      1. Wow thanks for the fast reply, i actually removed all of the padding and margins (as far as i am aware) but it doesn’t shrink the height of the header which i think is causing the actual white space

        1. Brad Dalton Avatar
          Brad Dalton

          Did you see my latest post?

          It shows you one way to remove the padding and margins which removes the white space from around the header image.

  40. got it! finally Yay! figured it out. thanks a million!

    1. Brad Dalton Avatar
      Brad Dalton

      Good stuff. Mind sharing?

  41. Hi Brad,
    So I have finally managed to follow most of your instructions, but I can’t get rid of the padding and the overall height of my header seems to have increased. I’m not sure what I’m doing wrong. Could you help? Thank you soooo much!!
    ruchira

  42. Hi Brad! Thanks SO much for this! It’s helped me so much. However, on the iPhone I’m still noticing TONS of padding. The padding on the iPad is just enough to actually look cool, but the iPhone makes it so you can’t even read text on the header. Also, when I upload the 1140×200 header WordPress still asks me to cut off about 40 or 50pxs (well, just guessing there! ha!) off the edge of the header image. I don’t mind because it’s just white space, but out of curiosity do you know how to get wordpress to stop asking you to crop headers? That’s always bugged me!

    Thanks so much!

    1. Brad Dalton Avatar
      Brad Dalton

      Hi Ashlee

      Good question. The code in your child themes functions file determines whether WordPress needs to crop the image.

      If you match these settings with your header image, it will be used as is:

      Otherwise, you will be forced to crop the image.

      Example:
      [code]

      //* Add support for custom header
      add_theme_support( ‘custom-header’, array(
      ‘header_image’ => ”,
      ‘header-selector’ => ‘.site-title a’,
      ‘header-text’ => false,
      ‘height’ => 110,
      ‘width’ => 320,
      ) );
      [/code]

      Any image you upload which is not the exact same size as whats in the code above 320 x 110, will be cropped. The solution is to change these settings.

      1. Thanks so much! I guess I didn’t explain this well enough. I followed your instructions here and the header is working well! I’m fine with it being slightly cropped, but it IS exactly the same size so I’m not sure why it’s still asking me to crop it?!

        My real problem right now is that the iphone version still looks horrible, with the header as a logo instead and a HUGE border/margin around it no matter what I do. Do you know if I’m missing some percentage somewhere in the media code? (Also, why is the media code in this theme so messy?! Everything seems just ‘off’ compared to the other Genesis themes I’m using on my other sites!) I really just need help with the Iphone part right now. The rest of mobile sizes look fine with a tiny border around the header but it’s still readable which is the important part. (It’s not on the iphone.) Thanks so much for all the help and tutorials here!

        1. Brad Dalton Avatar
          Brad Dalton

          Ashlee

          I would change the values for each class at the size you want to modify until you get it looking the way you want.

          Everyone likes their sites to look different on different sized screens.

          1. Thanks so much for your help Brad! By class size do you mean the px #’s/widths in the media code? I’m not totally sure what you mean by that. It looks fine on everything Mini-ipad size and up. Thanks!

          2. Brad Dalton Avatar
            Brad Dalton

            Yes Ashlee. The value for the width in pixels.

            Just published a new post about how to customize the media queries for this theme.

  43. Hello,

    I got to the step about reducing the padding….I pasted the code like you said before the Media inquires (see below), but the padding still is there.
    [code]
    .site-header {
    background-color: #76d2c5;
    padding: 0px;
    padding: 0rem;
    overflow: hidden;
    }
    [/code]
    Here is the header right now on the site:

    Thank you for your help.
    Agnes

  44. Hi Brad, Thanks for these super helpful instructions. I’m stuck however at this stage: The value for the height in the default CSS code needs increasing so you can paste this code in after the first block which increases the value to 200px.
    [code]
    .header-image .site-title a {
    float: left;
    min-height: 200px;
    width: 100%;
    [/code]

    Where in the CSS code should I put this? I tried putting it before Media Queries on the .css style file, but it didn’t make any difference. I’ve sized my banner for the header to 1140×200, and still it gets chopped on the top and bottom. Don’t know what to do.

    I do want to keep the background yellow border. But I’d like to put my banner heading complete.
    thanks!
    ruchira

    1. Brad Dalton Avatar
      Brad Dalton

      All CSS code modifications should be added near the end of the file before the Media Queries unless they’re to do with mobile responsive design in which case you would add them to the respective media query sizes.

      Further customization of the solution in this tutorial is not covered at this stage.

  45. Christine Sharp Avatar
    Christine Sharp

    Hi again Brad. My header has now reverted to a thin header with the padding showing around it again. I’ve checked the code and everything I have pasted is still there. Weird. Any ideas?
    Chris

    1. Brad Dalton Avatar
      Brad Dalton

      When you re-size it?

      You will have to modify the CSS code if you want to remove the padding.

  46. Christine Sharp Avatar
    Christine Sharp

    Hi Brad,
    Thanks so much.
    I was able follow the steps successfully, but, even after pasting the code in as directed, I was not able to increase the height of my header to its full size – 200px. I pasted in the code (following) at the end of all the code in the style.css.
    I decreased the padding fine, but the header remains thin.
    Can you shed any light on this?
    Thank you.
    Chris

    1. Brad Dalton Avatar
      Brad Dalton

      Hello Cristine

      The code should be pasted before the Media Queries

      1. Hi Brad,
        Thanks for responding. I tried that – pasted the code before the Media Queries, plus I modified the CSS code for both re-sizing and padding, but my header remains thin with the padding showing. I cannot work out why.
        I’d very much appreciate any further advice.
        Thank you.
        Chris

        1. Brad Dalton Avatar
          Brad Dalton

          Chris

          I think the forum is the best place for this specific question.

          I have not included specific customization of mobile queries because different people like the design of their sites to look differently on different sized devices.

          1. Thanks, Brad. I appreciate your time. I’ll check the forum, though this was the best information I could find upon searching. The query is not related to customisation of mobiles – simply following your steps in this tutorial to apply to the blog header, but it does not appear to work on my header, for some reason. I’ll keep looking. Thanks again, Brad. Chris

          2. Brad Dalton Avatar
            Brad Dalton

            Hi Chris

            I will go over this again later and see if i can find another solution however it did work when i first tested it and others have found its works fine.

          3. Yes, strange. I am sure there must be a reason, but I do not know enough at this stage to pinpoint it. Thanks again, Brad. Your knowledge is very much appreciated.

  47. Chrissy Jee Avatar
    Chrissy Jee

    Thank you so much for putting this tutorial together! I have 2 questions:

    1. I followed your instruction and changed the color of the secondary nav to white. It looks great except you have to hover over the text for it to show up. Can this be fixed?

    2. I created a customized header at 1140×100. When I look at my site on my iPhone, the header image shrinks to fit on the screen but there is a red square box around it. Can this be changed?

    My website is: thedumplingmama.com

    1. Brad Dalton Avatar
      Brad Dalton

      Hi Crissy.

      Please add this code to the end of your child themes style.css file:
      [code]
      .nav-secondary {
      background-color: white;
      }

      .lifestyle-pro-red .archive-pagination li a,
      .lifestyle-pro-red .genesis-nav-menu .current-menu-item > a,
      .lifestyle-pro-red .genesis-nav-menu .sub-menu a,
      .lifestyle-pro-red .nav-secondary a {
      color: #a5a5a3;
      }
      [/code]

      1. Chrissy Jee Avatar
        Chrissy Jee

        Worked. Thank you!

        1. Brad Dalton Avatar
          Brad Dalton

          No worries Crissy

    2. Brad Dalton Avatar
      Brad Dalton

      No.2. I answered this yesterday on the Sp forums with all the code i modified for the Media Queries so that the background color is removed when the screen is re-sized.

      1. Chrissy Jee Avatar
        Chrissy Jee

        This also worked. Thank you for all your help.

      2. Adam Booth Avatar
        Adam Booth

        Hi Brad,

        I’m having the same issue as Chrissy with the background colour being visible around the header image on a mobile device. I have tried to find the post you’re referring to on the sp forum but am having no luck. Could you post a link?

        1. Brad Dalton Avatar
          Brad Dalton

          Hi Adam

          You can use Firebug to find the class and remove it.

  48. Yes I just realised I pasted in the code rather than change the values in the code that is already there.

    All done except the site title is not showing up and I am guessing that is because the text is #fff and I am trying to find where it is?

    1. Brad Dalton Avatar
      Brad Dalton

      You’ll find it in your style sheet under the Header section

  49. Francisco Avatar

    This is a great help and is exactly what I was looking for!

    One additional question: do you think it’s possible to also make the full-size header image mobile responsive, e.g. perhaps use media queries in the CSS to swap out and deliver an alternate smaller “mobile-friendly header image” when a mobile browser is accessing the site? Otherwise, I suspect the larger header image would be delivered and resized to fit the smaller screen.

    1. Brad Dalton Avatar
      Brad Dalton

      Does your header image re-size when you re-size the screen?

      1. Francisco Avatar

        Hi Brad – yes, the larger 1140×200 header image does seem to re-size when I view on a mobile device (and resizes again to yet another size when I view the mobile device portrait vs. landscape). In effect, the large 1140 wide header gets shrunken down so the entire thing fits in the smaller width of the mobile screen. So any logo within that image (and everything else) shrinks proportionately to the mobile screen size.

        However, I’m wondering: suppose we deliver a totally different header image that is more appropriately formatted for a mobile screen (e.g. using media queries in CSS)? In effect, we’d have 2 different header images, one for full-size screens and another header image that’s more “stripped down” for mobile devices with screens smaller than a particular size/resolution. (e.g. the mobile header image might only show the company logo, whereas the “full size” header image would encompass logo, tagline and other design elements within the image itself).

        Do you think that might be a good approach, or is such a thing even possible?

        Thanks!

        1. Brad Dalton Avatar
          Brad Dalton

          There are plugins for this however i don’t think they’re needed.

          When i tested a full width header image it re-sized perfectly

          1. I followed all of the instructions and got it to work mostly. First of all, thank you. By mostly, I mean for some reason the full width image ran off the right margin. For a quick fix I edited the image so it wasn’t so obvious, but i’m not sure why that’s happening. Then, even though my image was exactly 1140×200, it still cut it off until i edited the CSS down to a width of 1090.
            Honestly the site is passable as is but now I notice I have the same problem others are having with the lack of mobile responsiveness. On my phone, the padding comes back and only 25% of the header is visible. I suspect the reason my CSS needed to be compensated to 1090, and the lack of mobile responsiveness is the same problem. Do you have a plugin that you recommend?

          2. Brad Dalton Avatar
            Brad Dalton

            You would need to remove the padding in the Media Queries as well at different screen sizes.

            I doubt there is an easy solution with this theme.

      2. Francisco Avatar

        Hi Again – Following up on my previous comment, think I figured it out:

        Line 1894-95 of the CSS governs the header image shrinking on small mobile screens up to 767px wide. That has the rule “background-size: contain !important;”. However for screens wider than 768, the rule “background-position: center !important;” takes effect (e.g. as shown on line 1796-97).

        So for full screens screens, or medium screens like iPads held in portrait, the header image in effect gets cropped, but for smaller screens like iphones, the header gets resized rather than cropped due to the additional “center” rule.

        I guess we could hard-code delivery of an alternate header image in lines 1894-95 that would be applicable only to the smaler mobile screens like iphones etc. E.g., we could replace the “background-position: center” rule with something like: “background: url(images/);” Of course, this image would need to be uploaded manually to the server.

        What do you think of such an approach? And, thanks again.

        1. Brad Dalton Avatar
          Brad Dalton

          When i tested the default image it re-sizes perfectly so i didn’t see an need to do that however you could try it and see the result.

          1. I am having the same issue. I made it the large header size, but when looking at it on my phone, the entire header image shrinks to a small little thing.

          2. Brad Dalton Avatar
            Brad Dalton

            Yes. You’ll need to add CSS to the Media Queries to fix that.

            There’s a couple of extra posts i wrote about removing the padding etc at the end of the post.

            Hard to cover individual circumstances because of all the different variables.

  50. Hi,
    I added the code to the functions file but the header upload screen still says the original 320x dimensions.

    I am on the latest version of Genesis

    1. Brad Dalton Avatar
      Brad Dalton

      Hello David

      Which code?

      1. David Bennett Avatar
        David Bennett

        Hi Brad,
        The ‘//* Add support for custom header’ code.

        I just switched to the Beautiful Pro theme but I switch back to Lifestyle Pro now.

        1. Brad Dalton Avatar
          Brad Dalton

          You need to follow all the steps.

          The PHP code for the custom header only applies to what size you upload.

          You will also need to modify the CSS code to match your header size and remove the padding.

          1. David Bennett Avatar
            David Bennett

            I did and it doesn’t make any difference. It still says ‘Images of exactly 320 × 110 pixels will be used as-is.’

          2. Brad Dalton Avatar
            Brad Dalton

            You need to change the values in the PHP code to match the exact same size as your image.

  51. Any idea how to get that widget to work. When I do this but make my header image 640 X 150 px and I add a search button to the header widget it pushes my image to be left aligned (OK) but the widget background area extends over it and cuts off half of my header image.

    1. Brad Dalton Avatar
      Brad Dalton

      Try reducing the width of the header right widget by the same value as you increased the header image area

      1. Hi Brad! Where do you adjust the widget width? I’ve in the style.css file under “Widget Area” (.site-header .widget-area) and reduced the default 600 to 400 and while the widget area was reduced, it still cut off half of my header image (almost as if a padding or something was spilling over it). Any ideas?

        1. Brad Dalton Avatar
          Brad Dalton

          That’s the right way to change the header widget width however you will also need to increase the value for your header image which depends on how you added it.

          You’ll find most of the code for the header in the same section of the file so you can try increasing any values which affect the header to see if that fixes the problem.

          Did you use the Custom Header uploader or CSS to add your header image?

          The custom header uploader uses PHP so you will also need to change the values in your functions file so they are exactly the same as your image size and then increase the values in your CSS.

  52. Chrissy Jee Avatar
    Chrissy Jee

    Can you explain “paste this code in after the first block “? Where in the code is this?

    1. Brad Dalton Avatar
      Brad Dalton

      Paste it at the end of your child themes style.css file

      1. Chrissy Jee Avatar
        Chrissy Jee

        Worked. Thanks!

        1. Brad Dalton Avatar
          Brad Dalton

          No worries Chrissy.

Leave a Reply

Join 5000+ Followers

Get The Latest Free & Premium Tutorials Delivered The Second They’re Published.