<ruby id="bdb3f"></ruby>

    <p id="bdb3f"><cite id="bdb3f"></cite></p>

      <p id="bdb3f"><cite id="bdb3f"><th id="bdb3f"></th></cite></p><p id="bdb3f"></p>
        <p id="bdb3f"><cite id="bdb3f"></cite></p>

          <pre id="bdb3f"></pre>
          <pre id="bdb3f"><del id="bdb3f"><thead id="bdb3f"></thead></del></pre>

          <ruby id="bdb3f"><mark id="bdb3f"></mark></ruby><ruby id="bdb3f"></ruby>
          <pre id="bdb3f"><pre id="bdb3f"><mark id="bdb3f"></mark></pre></pre><output id="bdb3f"></output><p id="bdb3f"></p><p id="bdb3f"></p>

          <pre id="bdb3f"><del id="bdb3f"><progress id="bdb3f"></progress></del></pre>

                <ruby id="bdb3f"></ruby>

                ThinkChat2.0新版上線,更智能更精彩,支持會話、畫圖、視頻、閱讀、搜索等,送10W Token,即刻開啟你的AI之旅 廣告
                ``` <?php namespace think; use think\View; use think\Config; /** * 插件基類 * Lyc by www.studyfox.cn */ abstract class Addons { protected $view = null; //視圖實例對象 public $addons_path = ''; // 當前插件目錄 public function __construct() { // 獲取當前插件目錄 $this->addons_path = ADDON_PATH . $this->getName() . DS; // 初始化視圖模型 $config = ['view_path' => $this->addons_path]; $config = array_merge(Config::get('template'), $config); //修改模板路徑 $this->view = new View($config); } /** * 解析和獲取模板內容 用于輸出 * @param string $template 模板文件名或者內容 * @param array $vars 模板輸出變量 * @param array $replace 替換內容 * @param array $config 模板參數 * @return string */ public function fetch($template = '', $vars = [], $replace = [], $config = []) { if(!is_file($template)){ $template = DS . $template; } echo $this->view->fetch($template, $vars, $replace, $config); } /** * 獲取當前插件名 * @return [string] [返回類似book] * final 子類不能重寫 */ final public function getName() { $data = explode('\\', get_class($this));; // get_class返回定義的類名 // array_pop 刪除數組中最后一個元素,array_pop的值為所刪除的元素 return strtolower(array_pop($data)); // strtolower大寫轉小寫 } // 安裝插件(必須實現) abstract public function install(); // 卸載插件(必須實現) abstract public function uninstall(); } ```
                  <ruby id="bdb3f"></ruby>

                  <p id="bdb3f"><cite id="bdb3f"></cite></p>

                    <p id="bdb3f"><cite id="bdb3f"><th id="bdb3f"></th></cite></p><p id="bdb3f"></p>
                      <p id="bdb3f"><cite id="bdb3f"></cite></p>

                        <pre id="bdb3f"></pre>
                        <pre id="bdb3f"><del id="bdb3f"><thead id="bdb3f"></thead></del></pre>

                        <ruby id="bdb3f"><mark id="bdb3f"></mark></ruby><ruby id="bdb3f"></ruby>
                        <pre id="bdb3f"><pre id="bdb3f"><mark id="bdb3f"></mark></pre></pre><output id="bdb3f"></output><p id="bdb3f"></p><p id="bdb3f"></p>

                        <pre id="bdb3f"><del id="bdb3f"><progress id="bdb3f"></progress></del></pre>

                              <ruby id="bdb3f"></ruby>

                              哎呀哎呀视频在线观看