The WordPress® custom header function makes it possible for you to upload a header graphic, or logo, for your site.1 The heavy lifting of adding the custom header function is built into Genesis and only needs to be activated on the child theme level.
Many of our child themes already include the code necessary to activate the custom header function.
To activate the custom header function in your Genesis child theme (if it’s not already included), you’ll need to edit the functions.php file.
Learn how to edit your child theme files using FTP.
First, locate the following line of code in your functions.php file:
require_once(TEMPLATEPATH.’/lib/init.php’);
The code you’ll add to activate the custom header function must be placed somewhere after this line of code.
Next, check to see if your functions.php file contains this closing code:
?>
If it does, the code you’ll add to activate the custom header function must be placed somewhere before this closing code.
Finally, add the following code (somewhere between the lines mentioned above) to activate the custom header function in your child theme:
Custom Header Parameters
- ‘width’: integer, default is 960
- ‘height’: integer, default is 80
- ‘textcolor’: hexadecimal value with no leading #, default is 333333
- ‘no_header_text’: boolean, default is false
- ‘header_image’: path/to/image.png, defaults to child theme’s images/header.png
- ‘header_callback’: function name, default is genesis_custom_header_style
- ‘admin_header_callback’: function name, default is genesis_custom_header_admin_style.
