📄 downloads.php
字号:
<?php // $Id: downloads.php,v 1.16.4.2 2008/12/10 06:30:24 dongsheng Exp $ require_once("../../config.php"); require_once($CFG->libdir.'/filelib.php');# this is the upload/download plugin, which allows to put arbitrary binary# files into the ewiki database using the provided specialized form, or the# standard image upload form below every edit page (if EWIKI_ALLOW_BINARY)#-- settings# Defined in view.php#define("EWIKI_UPLOAD_MAXSIZE", 2*1024*1024);define("EWIKI_PAGE_UPLOAD", "FileUpload");define("EWIKI_PAGE_DOWNLOAD", "FileDownload");define("EWIKI_ACTION_ATTACHMENTS", "attachments"); #-- define to 0 to disable#-- register plugin (main part)$ewiki_plugins["page"][EWIKI_PAGE_UPLOAD] = "ewiki_page_fileupload";$ewiki_plugins["page"][EWIKI_PAGE_DOWNLOAD] = "ewiki_page_filedownload";$ewiki_plugins["action"]["binary"] = "ewiki_binary";#-- allow per-page downloadsif (defined("EWIKI_ACTION_ATTACHMENTS") && EWIKI_ACTION_ATTACHMENTS) { $ewiki_plugins["action"][EWIKI_ACTION_ATTACHMENTS] = "ewiki_action_attachments"; $ewiki_config["action_links"]["view"][EWIKI_ACTION_ATTACHMENTS] = "Attachments";}#-- icons (best given absolute to www root)/*$ewiki_binary_icons = array( ".bin" => "/icons/exec.gif", "application/" => "/icons/exec.gif", "application/octet-stream" => "/icons/exec.gif", ".ogg" => "/icons/son.gif", ".jpeg" => "/icons/pic.gif", "text/" => "/icons/txt.gif", ".pdf" => "/icons/txt.gif",);*/#-- the upload function __can__ use different sections$ewiki_upload_sections = array( "" => "main",# "section2" => "section2",);#-- text, translations$ewiki_t["en"]["UPLOAD0"] = "Use this form to upload an arbitrary binary file into the wiki:<br />";$ewiki_t["en"]["UPL_NEWNAM"] = "Save with different filename";$ewiki_t["en"]["UPL_INSECT"] = "Upload into section";$ewiki_t["en"]["UPL_TOOLARGE"] = "Your upload has been rejected, because that file was too large!";$ewiki_t["en"]["UPL_REJSECT"] = 'The given download section "$sect" has been rejected. Please only use the default ones, or tell the WikiAdmin to reenable per-page uploads; else others can\'t find your uploaded files easily.<br /><br />';$ewiki_t["en"]["UPL_OK"] = "Your file was uploaded correctly, please see <a href=\"\$script".EWIKI_PAGE_DOWNLOAD."\">".EWIKI_PAGE_DOWNLOAD."</a>.<br /><br />";$ewiki_t["en"]["UPL_ERROR"] = "We're sorry, but something went wrong during the file upload.<br /><br />";$ewiki_t["en"]["DWNL_SEEUPL"] = 'See also <a href="$script'.EWIKI_PAGE_UPLOAD.'">FileUpload</a>, this page is only about downloading.<br /><br />';$ewiki_t["en"]["DWNL_NOFILES"] = "No files uploaded yet.<br />\n";$ewiki_t["en"]["file"] = "File";$ewiki_t["en"]["of"] = "of";$ewiki_t["en"]["comment"] = "Comment";$ewiki_t["en"]["dwnl_section"] = "download section";$ewiki_t["en"]["DWNL_ENTRY_FORMAT"] = '<div class="download"><a href="$url">$icon$title</a><small>$size<br />'. 'uploaded on <b>$time</b>, downloaded <tt>$hits</tt> times<br />'. '(<a href="$url">$id</a>)<br />'. '$section'.'file is of type <tt>$type</tt>'. '$comment'."</small></div><br />\n";$ewiki_t["de"]["UPLOAD0"] = "Mit diesem Formular kannst du beliebige Dateien in das Wiki abspeichern:<br />";$ewiki_t["de"]["UPL_NEWNAM"] = "Mit unterschiedlichem Dateinamen speichern";$ewiki_t["de"]["UPL_INSECT"] = "Hochladen in Bereich:";$ewiki_t["de"]["UPL_TOOLARGE"] = "Deine Datei wurde nicht aufgenommen, weil sie zu gro锟
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -