Beispiel #1
0
 function domanage()
 {
     Admin::MP("menu_template_manage");
     $dir = trim($_GET["dir"]);
     $L = FS::folder($dir, "templates", "");
     include admincp::tpl();
 }
Beispiel #2
0
 function doFile($do = null)
 {
     $dir = trim($_GET["dir"]);
     $type = $_GET["type"];
     $click = $_GET["click"];
     $from = $_GET["from"];
     $Folder = $do == 'template' ? 'templates' : $this->iCMS->config['uploadfiledir'];
     $callback = $_GET["callback"];
     $L = FS::folder($dir, $Folder, $type);
     include admincp::tpl("files.manage.file");
 }
Beispiel #3
0
 function domanage()
 {
     Admin::MP("menu_file_manage");
     $method = $_GET['method'];
     if ($method == 'database') {
         $sql = "";
         $_GET['aid'] && ($sql = " WHERE `aid`='" . (int) $_GET['aid'] . "'");
         $_GET['type'] == 'image' && ($sql = " WHERE ext IN('jpg','gif','png','bmp','jpeg')");
         $_GET['type'] == 'other' && ($sql = " WHERE ext NOT IN('jpg','gif','png','bmp','jpeg')");
         $maxperpage = 30;
         $total = $page == 1 || empty($_GET['rowNum']) ? iCMS_DB::getValue("SELECT count(*) FROM `#iCMS@__file` {$sql}") : (int) $_GET['rowNum'];
         $totalSize = iCMS_DB::getValue("SELECT SUM(size) FROM `#iCMS@__file` {$sql}");
         page($total, $maxperpage, "个文件");
         $rs = iCMS_DB::getArray("SELECT * FROM `#iCMS@__file` {$sql} order by `id` DESC LIMIT {$this->firstcount} , {$maxperpage}");
         $_count = count($rs);
         include admincp::tpl("files.manage.database");
     } else {
         $Folder = $do == 'template' ? 'templates' : $this->iCMS->config['uploadfiledir'];
         $L = FS::folder('', $Folder, $type);
         include admincp::tpl("files.manage.file");
     }
 }