Artikel

Hierarchisches Content-Modul mit Hauptkategorien und Kategorien. Jeder Artikel kann Bilder, Video-Streams, Videodateien, Links und Downloads enthalten. Unterstützt User-Zuordnung und Highlight-Flag.

Liste

getArticleList($config, $mediaCheck = "false")

Gibt Artikel zurück. Filtert nach Kategorie, Hauptkategorie, User, Label und Status. Enthält Medien-Zähler, zugeordnete Links und Downloads.

$config = [];
$config["website"] = '1';
$config["status"] = '1';
$config["maincategorie"] = ''; // optional: Hauptkategorie-ID
$config["categorie"] = ''; // optional: Kategorie-ID
$config["user"] = ''; // optional: User-ID
$config["label"] = '';
$config["search"] = '';
$config["orderby"] = 'date'; // id | date | headline | random
$config["direction"] = 'desc';
$config["start"] = '0';
$config["limit"] = '10';

$articles = getArticleList($config);

foreach ($articles as $a) {
    echo $a["headline"];
    echo $a["subheadline"]; // Unterüberschrift
    echo $a["shortcontent"]; // Kurzbeschreibung
    echo $a["content"]; // Hauptinhalt (HTML)
    echo date("d.m.Y", $a["date"]);
    echo $a["image"]["image"]; // Erstes Bild
    echo $a["image_items"]; // Anzahl Bilder
    // Autoren:
    foreach ($a["user"] as $user) {
        echo $user["firstname"].' '.$user["lastname"];
    }
    // Links:
    foreach ($a["links"] as $link) {
        echo '<a href="'.$link["url"].'">'.$link["button"].'</a>';
    }
    // Downloads:
    foreach ($a["downloads"] as $dl) {
        echo '<a href="'.$dl["file"].'">'.$dl["button"].'</a>';
    }
}
KeyBeschreibungWerte
websiteWebsite-IDSITE_ID · 'all'
statusStatusfilter'1' · '0' · leer
maincategorieFilter nach Hauptkategorie-IDID
categorieFilter nach Kategorie-ID (übersteuert Sortierung aus Kat.)ID
userFilter nach zugeordnetem UserUser-ID
labelLabel-ID FilterID
searchFreitextsuche in Titel und TagsBegriff
orderbySortierfeld'id' · 'date' · 'headline' · 'random'
directionRichtung'asc' · 'desc'
start / limitPaginationInteger
KeyBeschreibung
id / key / tagsBasisdaten
headlineTitel
subheadlineUnterüberschrift
shortcontentKurzbeschreibung / Teaser
contentHauptinhalt (HTML)
descriptionMeta-Beschreibung (SEO)
dateVeröffentlichungsdatum (Unix-Timestamp)
maincategorie / categorieKategorie-IDs
highlight'1' wenn aktives Highlight, sonst nicht gesetzt
status / updateStatus und letztes Update
user[].id / .firstname / .lastname / .emailZugeordnete Autoren
links[].referenz / .url / .target / .buttonVerknüpfte Links
link["website"] / link["facebook"] / ...Shortcut-Keys nach Referenz-Typ
downloads[].id / .button / .referenz / .file / .typDownloads
image_items / video_items / videofile_items / media_itemsAnzahl Medien
image[].image / .thumbnail / .smallBilder (Array, erstes Element = Hauptbild)
video[].embed / .urlVideo-Streams (eingebettete iframes)
videofile[].video / .width / .heightHochgeladene Videodateien
[
    {
        "id": "24",
        "key": "Test16-05-2023-090324",
        "tags": "",
        "headline": "Test 1 ad",
        "subheadline": "Testen der Links 1",
        "shortcontent": "

Tiktok Fontawsome Test 1<\/p>", "content": "

Tiktok<\/p>", "description": "blub", "date": "1771633200", "maincategorie": "0", "categorie": "0", "label": [ "6" ], "website": [ "1" ], "status": "1", "update": "2026-02-21 01:20:42", "links": [ { "referenz": "email", "url": "mailto:info@danceinn.ch", "target": "_blank" }, { "referenz": "phone", "url": "tel:+41719600324", "target": "_blank" }, { "referenz": "tiktok", "url": "https:\/\/www.tiktok.com\/de-DE", "target": "_blank" }, { "referenz": "facebook", "url": "https:\/\/www.facebook.com\/", "target": "_blank" }, { "referenz": "email", "url": "mailto:info@lagunabay.ch", "target": "_blank" }, { "referenz": "google", "url": "https:\/\/v1.laguna.thebandits.ch\/m\/food-drinks", "target": "_blank" } ], "link": { "email": "mailto:info@lagunabay.ch", "phone": "tel:+41719600324", "tiktok": "https:\/\/www.tiktok.com\/de-DE", "facebook": "https:\/\/www.facebook.com\/", "google": "https:\/\/v1.laguna.thebandits.ch\/m\/food-drinks" }, "downloads": [ { "id": "46", "button": "Tourflyer 2026", "referenz": "image", "file": "1770676817_Getrnkekarte.png", "typ": "png" } ], "image_items": 8, "video_items": 0, "videofile_items": 2, "media_items": 10, "image": { "id": "1413", "image": "media\/article\/articel\/image\/1413.webp", "thumbnail": "media\/article\/articel\/image\/thumbnail\/1413.webp", "small": "media\/article\/articel\/image\/small\/1413.webp", "check": "false" }, "video": [], "videofile": { "id": "310", "video": "media\/article\/articel\/video\/310.mp4", "check": "false" } }, { "id": "43", "key": "asdfadsfasdfadf09-02-2026-205543", "tags": "", "headline": "asdfadsfasdfadf", "subheadline": "", "shortcontent": "", "content": "

asdfasfasdfadf<\/p>", "description": "", "date": "1770670500", "maincategorie": "0", "categorie": "0", "label": [ "" ], "website": [ "4", "1" ], "status": "1", "update": "2026-02-09 21:55:32", "user": [ { "id": "1012", "firstname": "Edith", "lastname": "Gisler", "email": "edith.gisler@betasolutions.ch" } ], "image_items": 0, "video_items": 0, "videofile_items": 0, "media_items": 0, "image": [], "video": [], "videofile": [] }, { "id": "42", "key": "Test-neu-dasdfadsf09-02-2026-083342", "tags": "", "headline": "Test neu dasdfadsf", "subheadline": "", "shortcontent": "", "content": "

adfadsfa df<\/p>", "description": "", "date": "1770625980", "maincategorie": "13", "categorie": "68", "label": [ "" ], "website": [ "1" ], "status": "1", "update": "2026-02-09 09:34:06", "image_items": 0, "video_items": 0, "videofile_items": 0, "media_items": 0, "image": [], "video": [], "videofile": [] } ]

Playground