Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save n7studios/ac51e5701b5e7fa08eeca4aa4b810886 to your computer and use it in GitHub Desktop.
Save n7studios/ac51e5701b5e7fa08eeca4aa4b810886 to your computer and use it in GitHub Desktop.
Media Library Organizer: Tree View: Remove List View Drag + Drop Column
<?php
/**
* Plugin Name: Media Library Organizer: Tree View: Remove List View Drag + Drop Column
* Plugin URI: https://wpmedialibrary.com
* Version: 0.0.1
* Author: WP Media Library
* Author URI: https://wpmedialibrary.com
* Description: Remove Tree View's Drag and Drop Column in Media > List View
*/
/**
* Remove Tree View's Drag and Drop Column in Media > List View
*
* @since 0.0.1
*
* @param array $columns WP_List_Table Columns
* @return array WP_List_Table Columns
*/
function mlo_tree_view_remove_list_view_drag_drop_column( $columns ) {
// Remove columns as necessary
unset( $columns['tree-view-move'] );
// Return columns to display
return $columns;
}
add_filter( 'media_library_organizer_media_define_list_view_columns', 'mlo_tree_view_remove_list_view_drag_drop_column', 999 );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment