Created
April 1, 2014 16:34
-
-
Save fovoc/9917819 to your computer and use it in GitHub Desktop.
Disable Shoestrap 3 Gridder from homepage (this file should be placed in wp-content/mu-plugins/ folder, the homepage should be set manually)
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
<?php | |
add_filter( 'option_active_plugins', 'disable_gridder_in_homepage' ); | |
function disable_gridder_in_homepage($plugins){ | |
$homepage = 'local.wordpress.dev/'; | |
if( ( $_SERVER['HTTP_HOST'] . $_SERVER['REQUEST_URI']) == $homepage ) { | |
$key = array_search( 'shoestrap-gridder/shoestrap-gridder.php' , $plugins ); | |
if ( false !== $key ) { | |
unset( $plugins[$key] ); | |
} | |
} | |
return $plugins; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment