Created
May 27, 2016 14:12
-
-
Save sjaved87/726cbd3be22357308feb779dd1b95031 to your computer and use it in GitHub Desktop.
[Admin Ads] This will restrict admin ads to show on dashbaord page of network only.
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_action('admin_init', 'remove_admin_ads_from_other_pages'); | |
function remove_admin_ads_from_other_pages(){ | |
global $pagenow; | |
if($pagenow != 'index.php') | |
remove_action('admin_notices', 'admin_ads_output'); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment