From 1d8e97943f2ab3c0591765c788dc236fad41be1e Mon Sep 17 00:00:00 2001 From: rainbowsoft Date: Thu, 2 Nov 2023 17:33:13 +0800 Subject: [PATCH] =?UTF-8?q?=E8=8A=B1=E6=99=A8=E6=9C=88=E5=A4=95=E7=9A=84?= =?UTF-8?q?=E5=BB=BA=E8=AE=AE=EF=BC=8C=E4=BF=AE=E6=94=B9Template=E7=B1=BB;?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- zb_system/function/lib/template.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/zb_system/function/lib/template.php b/zb_system/function/lib/template.php index d90e03650..daa887188 100644 --- a/zb_system/function/lib/template.php +++ b/zb_system/function/lib/template.php @@ -218,7 +218,7 @@ public function CompileFiles() } } foreach ($this->templates as $name => $content) { - $s = RemoveBOM($this->CompileFile($content)); + $s = RemoveBOM($this->CompileFile($content, $name)); @file_put_contents($this->path . $name . '.php', $s); } } @@ -324,10 +324,10 @@ protected function addNonexistentTags() * * @return mixed */ - public function CompileFile($content) + public function CompileFile($content, $filename = '') { foreach ($GLOBALS['hooks']['Filter_Plugin_Template_Compiling_Begin'] as $fpname => &$fpsignal) { - $fpreturn = $fpname($this, $content); + $fpreturn = $fpname($this, $content, $filename); if ($fpsignal == PLUGIN_EXITSIGNAL_RETURN) { $fpsignal = PLUGIN_EXITSIGNAL_NONE;