Documentation - Actions / Filters - Filter – Admin – Hide Re-Order submenu item

Share on FacebookTweet about this on TwitterShare on Google+Share on LinkedInPrint this page

Filter – Admin – Hide Re-Order submenu item

This filter can be used to force hide /show the re-order interface, independently from the internal (admin) settings.



The following code will always hide the interface if the post type is “post” and the user id is 1

add_filter('apto/admin/reorder-interface/hide', 'apto_admin_reorder_interface_hide', 10, 2);
function apto_admin_reorder_interface_hide($hide_reorder_interface, $location_menu_data)
            global $userdata;
	    if($location_menu_data['post_type']    ==  "post"  && $userdata->ID == 1 )
                $hide_reorder_interface =   FALSE;
            return $hide_reorder_interface;	

*This code should be used within the theme or a custom plugin.