From 7e30c98ff86aac95e2caee529b13d9cb216a5769 Mon Sep 17 00:00:00 2001 From: filesite Date: Tue, 23 Apr 2024 23:33:48 +0000 Subject: [PATCH] add php extension php-mbstring check --- themes/tajian/controller/SiteController.php | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/themes/tajian/controller/SiteController.php b/themes/tajian/controller/SiteController.php index 6861b68..bda5e7e 100644 --- a/themes/tajian/controller/SiteController.php +++ b/themes/tajian/controller/SiteController.php @@ -8,6 +8,10 @@ require_once __DIR__ . '/../../../plugins/Parsedown.php'; Class SiteController extends Controller { public function actionIndex() { + if (function_exists('mb_strlen') == false) { + throw new Exception('Please install php extension php-mbstring first!', 500); + } + //获取数据 $menus = array(); //菜单,一级目录 $htmlReadme = ''; //Readme.md 内容,底部网站详细介绍