Filter Reference

wpdm_get_files – Manipulate WordPress Download Manager Package file list

1 min read Updated Jan 26, 2026

Description


Use this filter to manipulate like change order, hiding any specific file before showing the attached file list at frontend

Parameters


Two parameters are passed to this hook.

Usage


To add a new menu with author dashboard.

<?php add_filter('wpdm_get_files','wpdm_reorder_files',10,2);  ?>

Examples


<?php
add_filter('wpdm_get_files','wpdm_reorder_files',10,2);
// $menu_items is an array containing current menu items
function wpdm_reorder_files($files, $package){ 
//Code to change file list order 
return $files;
}
?>