From redaxo-multiglossar
Debugs MultiGlossar replacement engine internals in REDAXO including OUTPUT_FILTER hook, DOMDocument parsing, regex text replacement, template placeholders, and URL profile resolution for missing replacements, broken tooltips, addon integration, or performance issues.
npx claudepluginhub friendsofredaxo/claude-marketplace --plugin redaxo-multiglossarThis skill uses the workspace's default tool permissions.
Frontend replacement is executed in `boot.php` via `rex_extension::register('OUTPUT_FILTER', ...)` and delegated to `MultiGlossar\\Parser` (`lib/glossar/multiglossar.php`).
Guides Next.js Cache Components and Partial Prerendering (PPR): 'use cache' directives, cacheLife(), cacheTag(), revalidateTag() for caching, invalidation, static/dynamic optimization. Auto-activates on cacheComponents: true.
Processes PDFs: extracts text/tables/images, merges/splits/rotates pages, adds watermarks, creates/fills forms, encrypts/decrypts, OCRs scans. Activates on PDF mentions or output requests.
Share bugs, ideas, or general feedback.
Frontend replacement is executed in boot.php via rex_extension::register('OUTPUT_FILTER', ...) and delegated to MultiGlossar\\Parser (lib/glossar/multiglossar.php).
OUTPUT_FILTER receives the rendered page HTML.clang_id.This architecture avoids raw global string replacement and limits changes to parsed text nodes.
Key parser methods:
init_dom($source) - detects configured start/end scope, loads glossary rows, initializes ignored tags/classesparse_dom() - traverses the DOM and rebuilds final outputparse_childs($node) - recursive node walk with lock checkstext_replace($content) - regex-based term matching and replacement token strategy<!--exclude-->...<!--endexclude--> comment pairs are transformed into temporary elements and excluded from matching.
Replacement behavior includes:
term_alt are additional searchable markerscasesensitive)article_complete IDs where all matches are replaced\\b...\\b) to reduce accidental substring hitsReplacement markup is driven by config replace_definition. Supported placeholders include:
---DEFINITION---, ---URL---, ---TERM--- (escaped variants)---DEFINITION_RAW---, ---URL_RAW---, ---TERM_RAW--- (raw variants)This enables custom tooltip/link markup without touching PHP code.
resolveUrlKey() resolves the query key/namespace for glossary detail URLs:
gloss_id_<clangId>Url\\Profile or rex_url_generator_profileThis is important when URL profiles rewrite parameter names.
The parser normalizes certain UIkit tooltip patterns so configured output remains valid with dynamic definitions (for example converting direct data-uk-tooltip usage to a uk-tooltip="title: ..." format when needed).
a, headings, script, style, configured classes/tags).clang_id specific.