404 - Not Found
The requested file could not be found.
", 404);
}
@@ -139,7 +129,6 @@ function renderMultipleFiles(Context $ctx, array $files, string $pageDir): void
$pageMetadata = loadMetadata($pageDir);
- // Load page-level plugins
getPluginManager()->loadPagePlugins($pageMetadata);
$navigation = $ctx->navigation;
@@ -147,12 +136,10 @@ function renderMultipleFiles(Context $ctx, array $files, string $pageDir): void
$pageTitle = $pageMetadata['title'] ?? null;
$metaDescription = extractMetaDescription($pageDir, $pageMetadata);
- // Check for page-specific CSS
$pageCss = findPageCss($pageDir, $ctx->contentDir);
$pageCssUrl = $pageCss['url'] ?? null;
$pageCssHash = $pageCss['hash'] ?? null;
- // Check for cover image
$coverImage = findCoverImage($pageDir);
$socialImageUrl = null;
if ($coverImage) {
@@ -161,7 +148,6 @@ function renderMultipleFiles(Context $ctx, array $files, string $pageDir): void
$socialImageUrl = '/' . ($relativePath ? $relativePath . '/' : '') . $coverImage;
}
- // Let plugins add template variables
$templateVars = Hooks::apply(Hook::TEMPLATE_VARS, [
'content' => $content,
'navigation' => $navigation,
@@ -175,7 +161,6 @@ function renderMultipleFiles(Context $ctx, array $files, string $pageDir): void
extract($templateVars);
- // Wrap content with page template
ob_start();
require $ctx->templates->page;
$wrappedContent = ob_get_clean();