X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=src%2FApp.php;h=7622a1a0ce3aacb5e2795fbdd6b9c1e7b572e78e;hb=78a7e130ae7f5e5bca1fa51a49000ae3ef7a16f5;hp=1e24c3214f7030130060b0a620499fff45e57380;hpb=4f2ae8868431952bd3acda1537ee899740cbf205;p=friendica.git diff --git a/src/App.php b/src/App.php index 1e24c3214f..7622a1a0ce 100644 --- a/src/App.php +++ b/src/App.php @@ -11,7 +11,6 @@ use Friendica\Core\L10n; use Friendica\Core\PConfig; use Friendica\Core\System; use Friendica\Database\DBA; -use Friendica\Database\DBM; require_once 'boot.php'; require_once 'include/dba.php'; @@ -97,6 +96,41 @@ class App public $force_max_items = 0; public $theme_events_in_profile = true; + public $stylesheets = []; + public $footerScripts = []; + + /** + * Register a stylesheet file path to be included in the tag of every page. + * Inclusion is done in App->initHead(). + * The path can be absolute or relative to the Friendica installation base folder. + * + * @see App->initHead() + * + * @param string $path + */ + public function registerStylesheet($path) + { + $url = str_replace($this->get_basepath() . DIRECTORY_SEPARATOR, '', $path); + + $this->stylesheets[] = trim($url, '/'); + } + + /** + * Register a javascript file path to be included in the