Pro Verified

Name

Remove Wordpress Screen Option Items

About

Remove those annoying items in the Wordpress Dashboard

Language

PHP

Rating

Voted: 2 by 2 user(s)

How to Setup Snippet

Add to Code Snippets. If you are not using Elementor, then remove this line: remove_meta_box( 'e-dashboard-overview', 'dashboard', 'normal' );

Codevault

WebSquadron

Scroll down to see more snippets from this codevault.

Wordpress Compatability

The author has indicated that this snippet is compatable up to wordpress version: 6.1

Code Snippet Plugin Sync

Free & Pro

Download this snippet by clicking the download button, then head over to the Code Snippet Plugin settings in your wordpress admin dashboard, select the import menu then upload this file to import into your wordpress site.

Pro Only (Coming Soon)

You will be able to click a button and sync this snippet to your wordpress site automatically and from your dashboard manage all code snippets across all your wordpress sites that have the Code Snippets Pro plugin installed.

History

Last modified:

19/02/2024

Important Note

This snippet has the following status:

Pro Verified

This snippet has been verified by a Code Snippet Pro team member.

Pro Comments:

Remove Wordpress Screen Option Items

 
                    
1function remove_dashboard_widgets() {
2 remove_action( 'welcome_panel', 'wp_welcome_panel' );
3 remove_meta_box( 'dashboard_right_now', 'dashboard', 'normal' );
4 remove_meta_box( 'dashboard_activity', 'dashboard', 'normal' );
5 remove_meta_box( 'dashboard_quick_press', 'dashboard', 'side' );
6 remove_meta_box( 'dashboard_primary', 'dashboard', 'side' );
7 remove_meta_box( 'dashboard_site_health', 'dashboard', 'normal' );
8 remove_meta_box( 'e-dashboard-overview', 'dashboard', 'normal' );
9}
10add_action( 'wp_dashboard_setup', 'remove_dashboard_widgets' );

2

Featured Snippet

Related Snippets

Please see some snippets below related to this snippet..

WordPress Admin

AI Verified

1

Disable automatic scroll-to-notices when adding snippets

Added: 8 months ago

Last Updated: 8 months ago

By default, Code Snippets will scroll the page up so that new notices are visible when editing or adding snippets. This snippet disables that functionality for those who prefer a more consistent editi...

WordPress Admin

AI Verified

0

Add Featured Images to RSS Feeds

Added: 2 weeks ago

Last Updated: 2 weeks ago

Add the post thumbnail before the content in RSS feeds

WordPress Admin

Pro Verified

1

Hide Wordpress Dashboard Items based on User Role

Added: 1 year ago

Last Updated: 3 months ago

An expansion of a previous code where you can hide items from the WP Sidebar based on the User Role.

Other Snippets in this Codevault

These are some popular snippets from this users codevault..

Performance

AI Verified

32

Remove Unused Javascript

Added: 1 year ago

Last Updated: 3 days ago

Remove Unused Javascript - and improve your Page Speed Insight Score

WooCommerce

Pro Verified

10

Deactivate some WooCommerce Checkout Fields

Added: 1 year ago

Last Updated: 2 weeks ago

Deactivate some WooCommerce Checkout Fields from showing

Elementor

AI Verified

6

CSS Grid Aid

Added: 8 months ago

Last Updated: 1 month ago

This can be used for any WordPress Builder to aid working with CSS Grids.