Benutzer-Werkzeuge

Webseiten-Werkzeuge


addons:modules:lib_bootstrap

Bootstrap

Für die Nutzung des beliebten CSS Frameworks Bootstrap steht ein entsprechendes Bibliotheks-Modul zum Download bereit.

Die Einbindung in Templates und/oder Module erfolgt am einfachsten über die Dateien headers.inc.php und footers.inc.php.

headers.inc.php

$mod_headers = array(
    'backend' => array(
        'meta' => array(
            array( 'charset' => (defined('DEFAULT_CHARSET') ? DEFAULT_CHARSET : "utf-8") ),
            array( 'http-equiv' => 'X-UA-Compatible', 'content' => 'IE=edge' ),
            array( 'name' => 'viewport', 'content' => 'width=device-width, initial-scale=1' ),
        ),
        'css' => array(
            array('file'=>'modules/lib_bootstrap/vendor/css/bootstrap.min.css',),
            array('file'=>'modules/lib_bootstrap/vendor/css/bootstrap-editable.css',),
            array('file'=>'modules/lib_bootstrap/vendor/css/fuelux.min.css',),
            array('file'=>'modules/lib_bootstrap/vendor/css/font-awesome.min.css',),
        ),
        'jquery' => array(
            array(
                'core'    => true,
                'ui'      => true,
                'plugins' => array(),
            )
        ),
    )
);

Die Komponenten X-Editable, Fuel UX und Font Awesome sind natürlich optional! Ebenso die JQuery UI. Der JQuery Core muß aber geladen werden.

footers.inc.php

Bootstrap - bzw. die JavaScript Komponenten - sollte im Footer geladen werden. Auch hier sind X-Editable und Fuel UX optional.

$mod_footers = array(
    'backend' => array(
        'js' => array(
            '/modules/lib_bootstrap/vendor/js/bootstrap.min.js',
            '/modules/lib_bootstrap/vendor/js/bootstrap-editable.min.js',
            '/modules/lib_bootstrap/vendor/js/fuelux.min.js',
        )
    )
);

addons/modules/lib_bootstrap.txt · Zuletzt geändert: 2016/06/13 00:00 (Externe Bearbeitung)