GeneratePress Theme: 3.03
GP Premium: 1.12.3
WordPress: 5.7
Hi, I’m trying to disable the Sidebar on my Search Results page for my store. I’ve tried the following code found in other threads here in the forums by adding it to the “Code Snippets” plugin but it doesn’t seem to be working and the sidebar still shows up.
Code Snippets:
add_filter('generate_blog_masonry','generate_blog_woocommerce_masonry');
function generate_blog_woocommerce_masonry()
{
// Disable in WooCommerce
if ( is_woocommerce() )
return 'false';
// Check if blog
if ( is_home() )
return 'true';
// Otherwise, disable it
return 'false';
}
Any help would be greatly appreciated!
Thanks,
Jeff