A member of the StudioPress forum has asked to display Sub-Footer Left and Sub-Footer right on the Home page only. To do this, follow the instructions below.
Open up the functions.php file located in your child theme folder. Look for the following code starting around Line 85.
https://gist.github.com/cre8tivediva/82c95ced4cd7721f07c80c73db74ab40#file-functions-original-php
Replace that code with this:
https://gist.github.com/cre8tivediva/82c95ced4cd7721f07c80c73db74ab40#file-functions-php
Save the file. Clear your cache if that has been enabled on your website.
Lines 4 thru 6 tells your theme to display only on the home page.
That’s it!
I always avoid editing the (child) theme files so here’s another approach which leaves functions.php untouched:
add_action( 'genesis_after_content_sidebar_wrap', 'subfooter_only_on_home_page' );
function subfooter_only_on_home_page() {
if ( ! is_home() ) {
remove_action( 'genesis_before_footer', 'outreach_sub_footer', 5 );
}
}
This could be put in its own plugin file.
Hi Damien, thank you for taking the time to post that additional solution.