-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathboot.php
More file actions
16 lines (12 loc) · 769 Bytes
/
boot.php
File metadata and controls
16 lines (12 loc) · 769 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
<?php
$addon = rex_addon::get('module_styles');
if (rex::isBackend() && rex::getUser() && rex_url::currentBackendPage() === 'index.php?page=content/edit' && $addon->getConfig('module_stylesheet')) {
$styles = explode("\r\n", $addon->getConfig('module_stylesheet'));
rex_view::setJsProperty('moduleStylesheet', $styles);
rex_view::addJsFile($addon->getAssetsUrl('module-styles.js'));
}
if (rex::isBackend() && rex::getUser() && rex_url::currentBackendPage() === 'index.php?page=module_styles/settings' && $addon->getConfig('module_stylesheet')) {
$styles = explode("\r\n", $addon->getConfig('module_stylesheet'));
rex_view::setJsProperty('moduleStylesheet', $styles);
rex_view::addJsFile($addon->getAssetsUrl('module-styles-settings.js'));
}