Snippet: Hide Welcome Panel for WordPress Multisite

Add following snippet to “functions.php”

Snippet

add_action( 'load-index.php', 'fb_hide_welcome_panel_for_multisite' );
function fb_hide_welcome_panel_for_multisite() {
	if ( ! is_multisite() ) // don't check, if you will use this on single install of WP
		return;
	if ( 2 === (int) get_user_meta( get_current_user_id(), 'show_welcome_panel', TRUE ) )
		update_user_meta( get_current_user_id(), 'show_welcome_panel', 0 );
}

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>