Skip to content

Snippet: Conditionally Show/Hide The Footer Callout

The following snippet can be used to conditionally show/hide the Footer Callout section with code. So in this example we are hiding the Footer Callout for the front page only.

/**
 * Conditionally Show/Hide The Footer Callout.
 *
 * @link https://total.wpexplorer.com/docs/snippets/conditionally-showhide-the-footer-callout/
 */
add_filter( 'totaltheme/footer/callout/is_enabled', function( $check ) {
	if ( is_front_page() ) {
		$check = false; // Hide on the front page
	}
	return $check;
}, 20 );
All PHP snippets should be added via child theme's functions.php file or via a plugin. We recommend Code Snippets (100% Free) or WPCode (sponsored)
Back To Top