Snippets: Restrict Page Settings & Custom Fields To Admins Only

The following filter will hide the Total page settings metabox from any user except admins (so they will be hidden for authors/contributors)

if ( is_admin() && ! current_user_can( 'administrator' ) ) {
	add_filter( 'wpex_metaboxes', '__return_false' );
}
All PHP snippets should be added via a child theme's functions.php file.