0) ? $siblingDocs[$siblingIdx - 1] : null; $nextSibling = ($siblingIdx !== false && $siblingIdx < count($siblingDocs) - 1) ? $siblingDocs[$siblingIdx + 1] : null; // Build the canonical URL (include token for link-type so OG links work) $canonicalUrl = doc_url($topic['slug'], $doc['slug']); if ($accessType === 'link' && !empty($doc['access_token'])) { $canonicalUrl .= '?token=' . rawurlencode($doc['access_token']); } $meta = build_meta([ 'title' => $doc['title'] . ' — ' . $topic['title'], 'og_title' => $doc['title'], 'og_desc' => $doc['meta_description'] ?: get_setting('og_description'), 'og_image' => $ogImage, 'og_type' => 'article', 'og_url' => $canonicalUrl, ]); include ROOT_PATH . '/includes/header.php'; // ── Access denied: password form ────────────────────────────────────────────── if (!$accessOk && $accessType === 'password'): ?>
🔒 Password Required

This document is password protected.

← Back
🔗 Access Restricted

This document is only accessible via a special private link.

If you have received the link, please use it to access this document. Generic URL access is not permitted.

← Back to Topic
🔒 This document is password protected. Your access expires when your session ends.
⚠ This document is a draft and not publicly visible.
📄 Revision History
DateChanged ByNote