From 011800d42526ebb4acce4ce001dc53b97995ad53 Mon Sep 17 00:00:00 2001 From: jasonF1000 <116643854+jasonF1000@users.noreply.github.com> Date: Thu, 27 Apr 2023 16:51:46 +0200 Subject: [PATCH] changed PageContent.php to accept nested includes (#4192) * changed app/Entities/Tools/PageContent.php to accept nested include levels. Tested it and it works. * changed recommendations This loop is now only around parsePageIncludes and bugfixes the space indentation. * Update PageContent.php fix spaces --- app/Entities/Tools/PageContent.php | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/app/Entities/Tools/PageContent.php b/app/Entities/Tools/PageContent.php index b4bc8b91b13..67f3ea338f9 100644 --- a/app/Entities/Tools/PageContent.php +++ b/app/Entities/Tools/PageContent.php @@ -303,8 +303,10 @@ public function render(bool $blankIncludes = false): string if ($blankIncludes) { $content = $this->blankPageIncludes($content); - } else { - $content = $this->parsePageIncludes($content); + } else { + for ($includeDepth = 0; $includeDepth <= 3; $includeDepth++) { + $content = $this->parsePageIncludes($content); + } } return $content;