Search by

contao-dd / advanced-classes-bundle

visionpixelMDevster

Extend the CSS classes of Contao content elements and form fields with predefined sets (Bootstrap, Bulma, Materialize, Spectre)

Package info

github.com/Contao-DD/advanced-classes-bundle

Issues

Type:contao-bundle

pkg:composer/contao-dd/advanced-classes-bundle

Statistics

Installs: 46 545

Dependents: 3

Suggesters: 0

Stars: 10

2.0.0 2026-11-01 05:39 UTC

README

Latest Stable Version Total Downloads Latest Unstable Version License

Das Modul erweitert die CSS-Klassen der Contao-Inhaltselemente und Formularfelder durch selbst definierbare Sets an CSS-Klassen. Redakteure und Admins können über Select-Felder schnell auf vordefinierte CSS-Klassen zugreifen.

Für Bootstrap 4 und 5, Materialize, Bulma und Spectre.css wird bereits ein vordefiniertes Set für Spaltenbreite, Spalten-Offset, Reihenfolge und Sichtbarkeit mitgeliefert.

About

Extend the CSS classes of Contao content elements and form fields with predefined sets of CSS classes. Editors and admins can pick the classes via select fields.

Predefined sets for column width, offset, order and visibility are included for Bootstrap 4 and 5, Materialize, Bulma and Spectre.css.

Supported Entities All content elements with CSS settings (including content elements of news and events) and form fields.

Screenshots

Setting classes for bootstrap Local settings

Systemvoraussetzungen / System requirements

  • Contao 5.3 or 6
  • PHP 8.1 or higher (Contao 6 requires PHP 8.4)

Für Contao 4 nutze bitte Version 1.6 / For Contao 4 please use version 1.6.

Installation & Configuration

DE:

  • Installiere die Erweiterung über den Contao Manager oder mit composer require contao-dd/advanced-classes-bundle
  • Aktualisiere die Datenbank
  • Wähle das CSS-Klassen-Set in deiner Website-Startseite (für Inhaltselemente) bzw. im Formular (für Formularfelder) aus
  • Setze die gewünschten Klassen in den Elementen

EN:

  • Install the extension via the Contao Manager or with composer require contao-dd/advanced-classes-bundle
  • Update your database
  • Select the CSS class set in the root page settings (for content elements) or in the form settings (for form fields)
  • Set the classes of every element you wish

Upgrade

2.0

DE: Die Erweiterung lädt im Backend kein jQuery mehr. Erweiterungen, die sich darauf verlassen haben, müssen jQuery selbst einbinden. Die Sets für Bootstrap 2, Bootstrap 3 und Bootstrap 4 alpha wurden entfernt. Startseiten und Formulare, die eines dieser Sets nutzen, werden beim Aktualisieren der Datenbank auf „kein Set“ zurückgesetzt. Wer ein entferntes Set weiter braucht, kann es aus einer älteren Version kopieren und als eigenes Set registrieren (siehe unten).

EN: The extension no longer loads jQuery in the backend. Extensions that relied on this have to load jQuery themselves. The Bootstrap 2, Bootstrap 3 and Bootstrap 4 alpha sets have been removed. Root pages and forms using one of these sets are reset to "no set" when updating the database. If you still need a removed set, copy it from an older version and register it as a custom set (see below).

Eigenes Set / Custom Set

DE:

  • Lege eine JSON-Datei an (Beispiel) und lege sie z. B. im files-Ordner ab
  • Lege folgende Datei an oder bearbeite sie: contao/config/config.php
  • Füge in der config.php folgendes ein, um das Set zu registrieren. Anschließend muss der Cache im Contao Manager geleert werden.
<?php

$GLOBALS['customAdvancedClassesSets'][] = '/files/sets/custom-set.json';
  • Danach kann das Set in den Einstellungen ausgewählt werden.

EN:

  • Create a JSON file (Example), e.g. in the files directory
  • Create or edit the following file: contao/config/config.php
  • Add this code to the config.php to register the set. Then clear the cache in the Contao Manager.
<?php

$GLOBALS['customAdvancedClassesSets'][] = '/files/sets/custom-set.json';
  • Now you can choose the set in the settings.

License

LGPL-3.0-or-later