From c9b32a8a170922dd85fc1d820dafe653eca75368 Mon Sep 17 00:00:00 2001 From: 9007967 <33853639+9007967@users.noreply.github.com> Date: Mon, 24 Oct 2022 07:28:03 +0800 Subject: [PATCH] =?UTF-8?q?=E9=9A=90=E8=97=8F=E7=9C=9F=E5=AE=9E=E6=96=87?= =?UTF-8?q?=E4=BB=B6=E8=B7=AF=E5=BE=84?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/Html.php | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/Html.php b/src/Html.php index bcb2f50..9b35836 100644 --- a/src/Html.php +++ b/src/Html.php @@ -116,9 +116,10 @@ protected function getFileInfo() { $files = get_included_files(); $info = []; - + $rootPath = app()->getRootPath(); + foreach ($files as $key => $file) { - $info[] = $file . ' ( ' . number_format(filesize($file) / 1024, 2) . ' KB )'; + $info[] = str_replace($rootPath, DIRECTORY_SEPARATOR, $file) . ' ( ' . number_format(filesize($file) / 1024, 2) . ' KB )'; } return $info;