⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 downloads.php

📁 很棒的在线教学系统
💻 PHP
字号:
<?php#  this plugin appends the list of uploaded attachments at the bottom of#  each page, the downloads / attachments plugin must be loaded too##  you could alternatively define EWIKI_AUTOVIEW to 0, and call the#  ewiki_attachments() wrapper function anywhere on yoursite.phpif (!defined("EWIKI_AUTOVIEW") || !EWIKI_AUTOVIEW) {   $ewiki_plugins["view_append"][] = "ewiki_view_append_attachments";}$ewiki_t["en"]["ATTACHMENTS"] = "attachments";$ewiki_t["de"]["ATTACHMENTS"] = "Anh鋘ge";function ewiki_view_append_attachments($id, $data, $action) {   $o = '<hr /><h4><a href="' . ewiki_script(EWIKI_ACTION_ATTACHMENTS, $id) .        '">' . ewiki_t("ATTACHMENTS") . '</a></h4>';   $scan = 's:7:"section";' . serialize($id);   $result = ewiki_database("SEARCH", array("meta" => $scan));#### BEGIN MOODLE CHANGES - show attachments link only if there are attachments.####                      - don't show the attachments on the content page.    if (count($result->entries) <= 0) {        $o = '';    }//   $ord = array();//   while ($row = $result->get()) {//      $ord[$row["id"]] = $row["created"];//   }//   arsort($ord);////    foreach ($ord as $id => $uu) {    //        $row = ewiki_database("GET", array("id"=>$id));//        if (EWIKI_PROTECTED_MODE && EWIKI_PROTECTED_MODE_HIDING && !ewiki_auth($row["id"], $row, "view")) {//            continue;//        }           //        $o .= ewiki_entry_downloads($row, "*");    //    }#### END MOODLE CHANGES   return($o);}function ewiki_attachments() {   global $ewiki_title, $ewiki_id;   return(ewiki_view_append_attachments($ewiki_title, array("id"=>$ewiki_id), "view"));}?>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -