Created
February 24, 2013 12:54
-
-
Save braddalton/5023725 to your computer and use it in GitHub Desktop.
Prevents widgets from loading on a specific page. Change the page i.d or conditional tag.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
add_filter ('sidebars_widgets', 'remove_specific_pages_widget'); | |
function remove_specific_pages_widget( $sidebars_widgets ){ | |
if (is_page('007')) | |
$sidebars_widgets ['sidebar'] = false; | |
return $sidebars_widgets; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment