Skip to content
Snippets Groups Projects
Commit 388af120 authored by Jan-Hendrik Willms's avatar Jan-Hendrik Willms
Browse files

fixes #4143

Closes #4143

Merge request studip/studip!2986
parent a8a03184
No related branches found
No related tags found
No related merge requests found
...@@ -69,10 +69,6 @@ if (isset($_SERVER['SERVER_NAME'])) { ...@@ -69,10 +69,6 @@ if (isset($_SERVER['SERVER_NAME'])) {
$ABSOLUTE_URI_STUDIP .= $CANONICAL_RELATIVE_PATH_STUDIP; $ABSOLUTE_URI_STUDIP .= $CANONICAL_RELATIVE_PATH_STUDIP;
} }
// default ASSETS_URL and ASSETS_PATH, customize if required
$GLOBALS['ASSETS_URL'] = $ABSOLUTE_URI_STUDIP . 'assets/';
$GLOBALS['ASSETS_PATH'] = $ABSOLUTE_PATH_STUDIP . 'assets/';
// Check if instance is configured; redirect to install script if not // Check if instance is configured; redirect to install script if not
if (!file_exists($GLOBALS['STUDIP_BASE_PATH'] . '/config/config_local.inc.php') && php_sapi_name() !== 'cli') { if (!file_exists($GLOBALS['STUDIP_BASE_PATH'] . '/config/config_local.inc.php') && php_sapi_name() !== 'cli') {
require_once __DIR__ . '/classes/URLHelper.php'; require_once __DIR__ . '/classes/URLHelper.php';
...@@ -93,6 +89,14 @@ foreach($added_configs as $key => $value) { ...@@ -93,6 +89,14 @@ foreach($added_configs as $key => $value) {
$GLOBALS[$key] = $value; $GLOBALS[$key] = $value;
} }
// create ASSETS_URL and ASSETS_PATH if not customized in config_local.inc.php
if (!isset($GLOBALS['ASSETS_URL'])) {
$GLOBALS['ASSETS_URL'] = $ABSOLUTE_URI_STUDIP . 'assets/';
}
if (!isset($GLOBALS['ASSETS_PATH'])) {
$GLOBALS['ASSETS_PATH'] = $ABSOLUTE_PATH_STUDIP . 'assets/';
}
// If no ENV setting was found in the config files, assume ENV=production // If no ENV setting was found in the config files, assume ENV=production
if (!defined('Studip\ENV')) { if (!defined('Studip\ENV')) {
define('Studip\ENV', DEFAULT_ENV); define('Studip\ENV', DEFAULT_ENV);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment