-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathunmus_visibility.php
56 lines (43 loc) · 960 Bytes
/
unmus_visibility.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
<?php
/**
* Visbility
*
* @package unmus
* @since 0.9
*/
// Security: Stops code execution if WordPress is not loaded
if (!defined('ABSPATH')) { exit; }
/**
* Disable UpdraftPlus @ Admin Bar
*
* @since 0.9
*/
function unmus_disable_updraftplus_admin_bar() {
global $wp_admin_bar;
$wp_admin_bar->remove_menu('updraft_admin_node');
}
add_action('wp_before_admin_bar_render', 'unmus_disable_updraftplus_admin_bar', 999);
/**
* The annoying Message
*
* Plugin: UpdraftPlus
* Fades out the Message on WordPress Upgrade Page
*
* @since 0.8
*/
function unmus_updraft_message_invisible() {
// Get current page
global $pagenow;
// Run on specific pages only
if ( $pagenow == 'update-core.php') {
echo "
<style type='text/css'>
.updraft-ad-container {
display:none !important;
}
</style>
";
}
}
add_action( 'admin_head', 'unmus_updraft_message_invisible' );
?>