From 914369d2c38056f6af79a814548b1f4ec5432538 Mon Sep 17 00:00:00 2001 From: filesite Date: Wed, 10 Jul 2024 22:50:28 +0800 Subject: [PATCH] icon improve --- lib/DirScanner.php | 18 +++++++++++++----- themes/beauty/views/site/index.php | 4 ++-- 2 files changed, 15 insertions(+), 7 deletions(-) diff --git a/lib/DirScanner.php b/lib/DirScanner.php index 98258b0..70595f7 100644 --- a/lib/DirScanner.php +++ b/lib/DirScanner.php @@ -47,12 +47,16 @@ Class DirScanner { 'ico', //图标 'mp3', //音乐 'mp4', //视频 + 'mov', //视频 'ts', //视频 'm3u8', //视频 ); + + //暂未使用 + /* protected $maxReadFilesize = array( //默认每种文件读取内容最大大小 'txt' => 102400, //纯文本 - 'md' => 5242880, //纯文本 + 'md' => 5242880, //纯文本 'url' => 20480, //快捷方式 'jpg' => 512000, //图片 'jpeg' => 512000, //图片 @@ -60,11 +64,13 @@ Class DirScanner { 'webp' => 512000, //图片 'gif' => 512000, //图片 'ico' => 51200, //图标 - 'mp3' => 10485760, //音乐,10M - 'mp4' => 104857600, //视频,100M - 'ts' => 10485760, //视频,10M - 'm3u8' => 10485760, //视频,10M + 'mp3' => 10485760, //音乐,10M + 'mp4' => 104857600, //视频,100M + 'mov' => 104857600, //视频,100M + 'ts' => 10485760, //视频,10M + 'm3u8' => 10485760, //视频,10M ); + protected $securedFileExtensions = array( //开启Nginx防盗链的文件类型 'jpg', //图片 'jpeg', //图片 @@ -74,9 +80,11 @@ Class DirScanner { 'ico', //图标 'mp3', //音乐 'mp4', //视频 + 'mov', //视频 'ts', //视频 'm3u8', //视频 ); + */ public $scanTimeCost = 0; //上一次目录扫描耗时,单位:毫秒 public $isApi = false; //如果为API获取数据,则realpath只返回相对路径 diff --git a/themes/beauty/views/site/index.php b/themes/beauty/views/site/index.php index 051e16d..d747d0c 100644 --- a/themes/beauty/views/site/index.php +++ b/themes/beauty/views/site/index.php @@ -4,7 +4,7 @@