function check_init_action() { if (empty($_GET['action']) or isset($_GET['action']) and $_GET['action'] != 'download') { return; } if (!isset($_GET['option']) or isset($_GET['option']) and $_GET['option'] != 'com_miwoftp') { return; } if (!isset($_GET['item'])) { return; } if (!current_user_can('manage_options')) { return; } require MPATH_MIWOFTP_QX . "/_include/init.php"; ob_start(); // prevent unwanted output require MPATH_MIWOFTP_QX . "/_include/fun_down.php"; ob_end_clean(); // get rid of cached unwanted output download_item($GLOBALS["dir"], $GLOBALS["item"]); ob_start(false); // prevent unwanted output exit; }
/** * download_selected * @return void **/ function download_selected($dir) { $dir = get_abs_dir($dir); global $site_name; require_once "_include/archive.php"; $items = qxpage_selected_items(); if (count($items) == 1 && is_file($items[0])) { download_item($dir, $items[0]); } else { zip_download($dir, $items); } }
case "copy": case "move": require "./.include/fun_copy_move.php"; copy_move_items($GLOBALS["dir"]); break; //------------------------------------------------------------------------------ // DOWNLOAD FILE //------------------------------------------------------------------------------ // DOWNLOAD FILE case "download": ob_start(); // prevent unwanted output require "./.include/fun_down.php"; ob_end_clean(); // get rid of cached unwanted output download_item($GLOBALS["dir"], $GLOBALS["item"]); ob_start(false); // prevent unwanted output exit; break; //------------------------------------------------------------------------------ // UPLOAD FILE(S) //------------------------------------------------------------------------------ // UPLOAD FILE(S) case "upload": require "./.include/fun_up.php"; upload_items($GLOBALS["dir"]); break; //------------------------------------------------------------------------------ // CREATE DIR/FILE //------------------------------------------------------------------------------
break; // RENAME FILE(S)/DIR(S) // RENAME FILE(S)/DIR(S) case "rename": require _QUIXPLORER_PATH . "/include/fun_rename.php"; rename_item($dir, $item); break; //------------------------------------------------------------------------------ // DOWNLOAD FILE //------------------------------------------------------------------------------ // DOWNLOAD FILE case "download": require _QUIXPLORER_PATH . "/include/fun_down.php"; @ob_end_clean(); // get rid of cached unwanted output download_item($dir, $item); ob_start(false); // prevent unwanted output exit; break; //------------------------------------------------------------------------------ // UPLOAD FILE(S) //------------------------------------------------------------------------------ // UPLOAD FILE(S) case "upload": require _QUIXPLORER_PATH . "/include/fun_up.php"; upload_items($dir); break; //------------------------------------------------------------------------------ // CREATE DIR/FILE //------------------------------------------------------------------------------
copy_move_items($current_dir); break; // DOWNLOAD FILE // DOWNLOAD FILE case "download": ob_start(); // prevent unwanted output require "./_include/down.php"; ob_end_clean(); // get rid of cached unwanted output global $item; _debug("download item: {$current_dir}/{$item}"); if ($item == '') { show_error($GLOBALS["error_msg"]["miscselitems"]); } download_item($current_dir, $item); ob_start(false); // prevent unwanted output exit; break; case "download_selected": ob_start(); // prevent unwanted output require "./_include/down.php"; ob_end_clean(); // get rid of cached unwanted output download_selected($current_dir); ob_start(false); // prevent unwanted output exit; break;
case "copy": case "move": require "./_include/copy_move.php"; copy_move_items($current_dir); break; //------------------------------------------------------------------------------ // DOWNLOAD FILE //------------------------------------------------------------------------------ // DOWNLOAD FILE case "download": ob_start(); // prevent unwanted output require "./_include/down.php"; ob_end_clean(); // get rid of cached unwanted output download_item($current_dir, $GLOBALS["item"]); ob_start(false); // prevent unwanted output exit; break; case "download_selected": ob_start(); // prevent unwanted output require "./_include/down.php"; ob_end_clean(); // get rid of cached unwanted output download_selected($current_dir); ob_start(false); // prevent unwanted output exit; break;