Blog-Listen
Das Blog-List-Modul ist die Grundlage für mehrsprachige Modul- und Server-Dokumentation im ganzen Weinhold-Framework – inklusive der Übersichtsseite, auf der du diesen Beitrag gefunden hast, und der Struktur, in der dieser Beitrag selbst geschrieben ist.
Allgemein
Diese Seite nutzt dieses Modul
Die Übersicht auf weinify.de/module ist selbst mit dem Blog-List-Modul gebaut. Der Shortcode weinify_blog_list mit den Parametern tag, style, orderby und order rendert dort die Kachel-Übersicht aller Modul-Beiträge.
Zwei Formate
Für kurze Übersichtsseiten gibt es das einfache wf_de/wf_en-Format mit frei eingegebenem HTML. Für ausführliche Doku-Beiträge (wie diesen hier) gibt es das strukturierte weinhold_blog_list_de/weinhold_blog_list_en-Format mit benannten, einklappbaren Sektionen, automatischem Inhaltsverzeichnis und Entwickler-Tabellen. Beide Formate unterstützen denselben DE/EN-Umschalter.
Core-Hervorhebung
Posts mit dem Schlagwort core, wichtig oder benötigt werden in Listen-Ansichten automatisch nach oben sortiert und mit einem dezenten „Core“-Label hervorgehoben.
Tag-Übersetzungen & Icons
Unter Weinhold → Blog List → Tag-Übersetzungen & Icons lässt sich pro Schlagwort eine englische Übersetzung und ein Icon hinterlegen, die automatisch in der Badge-Anzeige (weinhold_blog_list_meta) und im englischen Sprachblock verwendet werden.
Shortcodes
| Shortcode | Beschreibung |
|---|
| weinify_blog_list | Rendert eine gefilterte Kachel-/Listen-Übersicht. Attribute: tag, style (cards/showcase/timeline/list), limit (Standard 9), orderby (title/date/menu_order), order (ASC/DESC), pin_core (1/0, Standard 1) |
| weinhold_blog_list_de,weinhold_blog_list_en | Deutscher bzw. englischer Inhaltsblock im strukturierten Format. Sind beide vorhanden, erscheint automatisch ein Umschalter |
| weinhold_blog_list_caption | Kurzbeschreibung, wird als Seitenüberschrift und als Kartentitel in Listen-Ansichten verwendet |
| weinhold_blog_list_meta | Zeigt alle Schlagwörter des Posts als Badges (ohne rein strukturelle Tags wie modul/weinhold-framework) |
| weinhold_blog_list_section | Benannte, einklappbare Sektion, erzeugt automatisch einen Eintrag im Inhaltsverzeichnis |
| weinhold_blog_list_h2 | Zwischenüberschrift innerhalb einer Sektion |
| weinhold_blog_list_devtable | Entwickler-Tabelle aus einfachem, spaltengetrenntem Text |
| weinhold_blog_list_collapse | Frei benannter, einklappbarer Textblock ohne Inhaltsverzeichnis-Eintrag |
| wf_de,wf_en,wf_caption,wf_h2,wf_devtable,wf_collapse | Legacy-Kurzformen für das einfache Format bzw. Alias-Namen der obigen Shortcodes – in neuem Inhalt die kanonischen weinhold_blog_list_*-Namen verwenden |
Dateien
modules/blog_list.php – einzige Datei des Moduls: alle Shortcode-Renderer, Sprachumschalter- und Inhaltsverzeichnis-JS, Tag-Metadaten-Verwaltung, Caption-Speicherung, Zurück-Button-Injektion.
Für Entwickler
Wie Devtables geparst werden
Erste Zeile ist die Kopfzeile, sie bestimmt die Spaltenanzahl. Danach wird jede Zeile in Leerzeichen-getrennte Tokens zerlegt; die ersten N-1 Spalten bekommen je ein Token zugewiesen, die letzte Spalte nimmt den kompletten Rest der Zeile. Endet ein Token mit einem Komma oder enthält es eine offene runde Klammer, läuft die Spalte über das nächste Leerzeichen hinaus weiter (z. B. bleibt „bigint, Auto-Increment“ oder „weinhold_…_get_rows( array $filters, …“ trotz enthaltener Leerzeichen und Kommas in einer Spalte). Seit 2026-09-22 wird daraus ein echtes HTML-table-Element gerendert (vorher nur Text mit br-Umbrüchen).
Inhaltsverzeichnis & Sprachumschalter
Beides läuft rein im Frontend-JS (weinhold_blog_list_inline_js()): buildTocs() sammelt alle Sektionen mit data-toc-title im aktuellen Scope und baut daraus automatisch eine Navigation samt „Alle auf-/zuklappen“-Button, initLangToggles() blendet je nach gewählter Sprache den passenden Block ein/aus und merkt die Wahl in localStorage unter dem Schlüssel weinhold_lang.
Naming-Fix: wf_* vs. weinhold_blog_list_*
Die kanonischen Shortcode-Namen sind weinhold_blog_list_*, die kürzeren wf_*-Namen existieren nur noch als Alias für bereits veröffentlichte, ältere Beiträge. In neuem Doku-Inhalt immer die langen Namen verwenden.
Besonderheiten
weinhold_blog_list_meta zeigt bewusst nicht zwischen „Kategorie“, „Geltungsbereich“ oder „Core“ unterschiedene Badges – im Code sind das alles einfach Tags wie jeder andere auch. Nur rein strukturelle, nicht unterscheidende Tags (modul, weinhold-framework, wichtig, benötigt) werden herausgefiltert.
Shortcodes innerhalb von weinhold_blog_list_collapse werden nicht per do_shortcode() aufgelöst – ein Shortcode wie eine Server-Einbettung darf deshalb nie in einem Collapse-Block stehen, sondern muss direkt auf Beitragsebene, außerhalb aller weinhold_blog_list_*-Wrapper platziert werden.
Der Zurück-Button am Ende jedes Beitrags sowie das Zuklappen/Aufklappen-Verhalten der Sektionen werden über den the_content-Filter automatisch injiziert – Autoren müssen dafür nichts zusätzlich in den Beitrag schreiben.
Versionshistorie
| Version | Datum | Änderung |
|---|
| 1.0.0 | 22.09.2026 | Einführung der Versionierung. |
Blog Lists
The Blog List module is the foundation for multilingual module and server documentation across the whole Weinhold Framework — including the overview page where you found this post, and the structure this very post is written in.
General
This Page Uses This Module
The overview at weinify.de/module is itself built with the Blog List module. The weinify_blog_list shortcode with the tag, style, orderby, and order parameters renders the card overview of all module posts there.
Two Formats
For short overview pages, there’s the simple wf_de/wf_en format with freely entered HTML. For detailed documentation posts (like this one), there’s the structured weinhold_blog_list_de/weinhold_blog_list_en format with named, collapsible sections, an automatic table of contents, and developer tables. Both formats support the same DE/EN toggle.
Core Highlighting
Posts tagged core, wichtig, or benötigt are automatically sorted to the top in list views and highlighted with a subtle „Core“ label.
Tag Translations & Icons
Under Weinhold → Blog List → Tag Translations & Icons, an English translation and an icon can be set per tag, automatically used in the badge display (weinhold_blog_list_meta) and in the English language block.
Shortcodes
| Shortcode | Description |
|---|
| weinify_blog_list | Renders a filtered card/list overview. Attributes: tag, style (cards/showcase/timeline/list), limit (default 9), orderby (title/date/menu_order), order (ASC/DESC), pin_core (1/0, default 1) |
| weinhold_blog_list_de,weinhold_blog_list_en | German or English content block in the structured format. When both are present, a toggle appears automatically |
| weinhold_blog_list_caption | Short description, used as the page heading and as the card title in list views |
| weinhold_blog_list_meta | Shows all of the post’s tags as badges (excluding purely structural tags like modul/weinhold-framework) |
| weinhold_blog_list_section | Named, collapsible section, automatically creates an entry in the table of contents |
| weinhold_blog_list_h2 | Subheading inside a section |
| weinhold_blog_list_devtable | Developer table built from plain, column-separated text |
| weinhold_blog_list_collapse | Freely titled, collapsible text block with no table-of-contents entry |
| wf_de,wf_en,wf_caption,wf_h2,wf_devtable,wf_collapse | Legacy short forms for the simple format, or aliases of the shortcodes above — use the canonical weinhold_blog_list_* names in new content |
Files
modules/blog_list.php – the module’s only file: all shortcode renderers, language-toggle and table-of-contents JS, tag metadata management, caption storage, back-button injection.
For Developers
How Devtables Are Parsed
The first line is the header row and determines the column count. Each following line is split into whitespace-separated tokens; the first N-1 columns each get one token, and the last column takes the entire rest of the line. If a token ends with a comma or contains an open parenthesis, that column keeps consuming tokens past the next space (e.g. „bigint, Auto-Increment“ or „weinhold_…_get_rows( array $filters, …“ stay in a single column despite containing spaces and commas). Since 2026-09-22 this is rendered as a real HTML table element (previously just text with br line breaks).
Table of Contents & Language Toggle
Both run purely in frontend JS (weinhold_blog_list_inline_js()): buildTocs() collects all sections with data-toc-title in the current scope and automatically builds a navigation plus an „expand/collapse all“ button; initLangToggles() shows/hides the matching block depending on the selected language and remembers the choice in localStorage under the key weinhold_lang.
Naming Fix: wf_* vs. weinhold_blog_list_*
The canonical shortcode names are weinhold_blog_list_*; the shorter wf_* names exist only as aliases for already-published, older posts. Always use the long names in new documentation content.
Special Cases
weinhold_blog_list_meta deliberately doesn’t distinguish badges by „category“, „scope“, or „core“ — in the code, they’re all just tags like any other. Only purely structural, non-distinguishing tags (modul, weinhold-framework, wichtig, benötigt) are filtered out.
Shortcodes inside weinhold_blog_list_collapse are not resolved via do_shortcode() — a shortcode like a server embed must therefore never sit inside a collapse block, but has to be placed directly at the post level, outside all weinhold_blog_list_* wrappers.
The back button at the end of every post, as well as the expand/collapse behavior of sections, are injected automatically via the the_content filter — authors don’t need to write anything extra into the post for that.
Version History
| Version | Date | Change |
|---|
| 1.0.0 | 22.09.2026 | Introduction of versioning. |