source/Core/Config.php
public function initVars($shopID)
    {
        $this->_loadVarsFromFile();

        $this->_setDefaults();

        $configLoaded = $this->_loadVarsFromDb($shopID);
        // loading shop config
        if (empty($shopID) || !$configLoaded) {
            // if no config values where loaded (some problems with DB), throwing an exception
            $exception = new \OxidEsales\Eshop\Core\Exception\DatabaseException(
                "Unable to load shop config values from database",
                0,
                new \Exception()
            );
            throw $exception;
        }

        // loading theme config options
        $this->_loadVarsFromDb($shopID, null, Config::OXMODULE_THEME_PREFIX . $this->getConfigParam('sTheme'));

        // checking if custom theme (which has defined parent theme) config options should be loaded over parent theme (#3362)
        if ($this->getConfigParam('sCustomTheme')) {
            $this->_loadVarsFromDb($shopID, null, Config::OXMODULE_THEME_PREFIX . $this->getConfigParam('sCustomTheme'));
        }

        // loading modules config
        $this->_loadVarsFromDb($shopID, null, Config::OXMODULE_MODULE_PREFIX);

        $this->loadAdditionalConfiguration();

        // Admin handling
        $this->setConfigParam('blAdmin', isAdmin());

        if (defined('OX_ADMIN_DIR')) {
            $this->setConfigParam('sAdminDir', OX_ADMIN_DIR);
        }

        $this->_loadVarsFromFile();
    }
public function initVars($shopID)
    {
        $this->_loadVarsFromFile();

        $this->_setDefaults();

        $configLoaded = $this->_loadVarsFromDb($shopID);
        // loading shop config
        if (empty($shopID) || !$configLoaded) {
            // if no config values where loaded (some problems with DB), throwing an exception
            $exception = new \OxidEsales\Eshop\Core\Exception\DatabaseException(
                "Unable to load shop config values from database",
                0,
                new \Exception()
            );
            throw $exception;
        }

        // loading theme config options
        $this->_loadVarsFromDb($shopID, null, Config::OXMODULE_THEME_PREFIX . $this->getConfigParam('sTheme'));

        // checking if custom theme (which has defined parent theme) config options should be loaded over parent theme (#3362)
        if ($this->getConfigParam('sCustomTheme')) {
            $this->_loadVarsFromDb($shopID, null, Config::OXMODULE_THEME_PREFIX . $this->getConfigParam('sCustomTheme'));
        }

        // loading modules config
        $this->_loadVarsFromDb($shopID, null, Config::OXMODULE_MODULE_PREFIX);

        $this->loadAdditionalConfiguration();

        // Admin handling
        $this->setConfigParam('blAdmin', isAdmin());

        if (defined('OX_ADMIN_DIR')) {
            $this->setConfigParam('sAdminDir', OX_ADMIN_DIR);
        }

        $this->_loadVarsFromFile();
    }
public function initVars ( $ shopID ) { $ this -> _loadVarsFromFile ( ) ; $ this -> _setDefaults ( ) ; $ configLoaded = $ this -> _loadVarsFromDb ( $ shopID ) ; // loading shop config if ( empty ( $ shopID ) || ! $ configLoaded ) { // if no config values where loaded (some problems with DB), throwing an exception $ exception = new \ OxidEsales \ Eshop \ Core \ Exception \ DatabaseException ( "Unable to load shop config values from database" , 0 , new \ Exception ( ) ) ; throw $ exception ; } // loading theme config options $ this -> _loadVarsFromDb ( $ shopID , null , Config :: OXMODULE_THEME_PREFIX . $ this -> getConfigParam ( 'sTheme' ) ) ; // checking if custom theme (which has defined parent theme) config options should be loaded over parent theme (#3362) if ( $ this -> getConfigParam ( 'sCustomTheme' ) ) { $ this -> _loadVarsFromDb ( $ shopID , null , Config :: OXMODULE_THEME_PREFIX . $ this -> getConfigParam ( 'sCustomTheme' ) ) ; } // loading modules config $ this -> _loadVarsFromDb ( $ shopID , null , Config :: OXMODULE_MODULE_PREFIX ) ; $ this -> loadAdditionalConfiguration ( ) ; // Admin handling $ this -> setConfigParam ( 'blAdmin' , isAdmin ( ) ) ; if ( defined ( 'OX_ADMIN_DIR' ) ) { $ this -> setConfigParam ( 'sAdminDir' , OX_ADMIN_DIR ) ; } $ this -> _loadVarsFromFile ( ) ; }
Initialize configuration variables

@throws \OxidEsales\Eshop\Core\Exception\DatabaseException
@param int $shopID
Initialize configuration variables