In this short blog post, we’ll show you a PHP function to disable drag metabox in WordPress Admin Dashboard.

PHP function to disable drag metabox in WordPress Admin Dashboard
<?php
/*--------------------------------------------------------------
DISABLE DRAG METABOX DASHBOARD
--------------------------------------------------------------*/
add_action( 'admin_init', 'btwp_disable_drag_metabox_dashboard' );
function btwp_disable_drag_metabox_dashboard() {
wp_deregister_script( 'postbox' );
}

Tags: wp, wordpress, dashboard, wp_deregister_script, php