I want to make a list of files in {dir_name} with download and delete.
I stuck between function editor_delete() and modul_delete_confirm_submit() , when I press delete button (first function) nothing happened. But I can't understand why ? And I don't know how to make dowload for files in the list.
I've been trying to fix a problem with my module, but
Here's my (shortened) code example:
<?php
if ($may_cache) {
$menu_type = MENU_CALLBACK |MENU_VISIBLE_IN_TREE
|MENU_MODIFIABLE_BY_ADMIN;
$retval[] = array(
"path" => "admin/module",
"title" => t("module"),
"access" => user_access('access module page'),
"callback" => "module_page",
"type" => $menu_type,
);
$retval[] = array('path' => 'admin/settings/module',
'title' => t('module'),
"access" => user_access('module configuration'),
'callback' => 'module_configure');
if(arg(2) == 'delete')
$retval[] = array('path' => 'admin/module/delete/'. arg(3), 'title' => '', 'access' => user_access('access module page'), 'type' => MENU_CALLBACK, 'callback' => 'editor_delete');
}
return($retval);
}
function module_page() {
$content .= _module_files_display3();
return($content);
}
function _module_files_display3() {
$header = array(t('File name'), array('data' => t('Operations'), 'colspan' => 2));
$dirname = 'mydir';