How to Add Custom Logo to Genesis Child Theme
There are a bunch of tutorials those would work for you to add the custom logo to Genesis child theme. However, for my the last project I had to craft custom logo functions for a client site’s theme. Here is the step I added to functions.php:
- Add custom logo function
- Display custom logo function
- Remove title/logo metabox from Genesis theme options page function
- Remove title/logo metabox from Genesis customizer function
Add Custom Logo to Genesis Child Theme
So, here is the code snippet to add the custom logo to child theme:
After adding this code to your theme’s functions.php, you’ll see something like the screenshot below.
Select your logo and save it. Let’s display your logo now. Add the code below to display the custom logo that has selected already.
You’ll see your custom logo displaying as like as the screenshot below after adding the code of displaying.
Okay, we have a metabox for selecting the option for the header; “Image Logo” and “Dynamic Text” in Genesis Theme Setting page. So, I think we don’t need that metabox anymore. Let’s remove it. Add the following function to your theme’s functions.php
I think we don’t need title/logo metabox in Genesis customizer also. So, here is the screenshot with red marking area going to remove.
Here is the code snippet to remove title/logo metabox from Genesis customizer:
We have done except adding few CSS line. If you want you could add them to your style.css
Here is the full snippet of adding the custom logo to Genesis child theme:
Leave feedback if face any issue. Then you’ll. Happy coding!