Index: trunk/admin/install.php =================================================================== diff -u -r4790 -r4867 --- trunk/admin/install.php (.../install.php) (revision 4790) +++ trunk/admin/install.php (.../install.php) (revision 4867) @@ -598,7 +598,7 @@ $rs->MoveNext(); } - $sql = 'DELETE FROM '.$g_TablePrefix.'Cache WHERE VarName = "config_files"'; + $sql = 'DELETE FROM '.$g_TablePrefix.'Cache WHERE VarName IN ("config_files","configs_parsed")'; $ado->Execute($sql); $include_file = $pathtoroot.$admin."/install/upgrade.php"; Index: trunk/core/kernel/session/session.php =================================================================== diff -u -r4853 -r4867 --- trunk/core/kernel/session/session.php (.../session.php) (revision 4853) +++ trunk/core/kernel/session/session.php (.../session.php) (revision 4867) @@ -149,10 +149,11 @@ * * @param Session $session * @param string $var_name + * @param mixed $default */ - function GetField(&$session, $var_name) + function GetField(&$session, $var_name, $default = false) { - return $this->DirectVars[$var_name]; + return isset($this->DirectVars[$var_name]) ? $this->DirectVars[$var_name] : $default; //return $this->Conn->GetOne('SELECT '.$var_name.' FROM '.$this->TableName.' WHERE `'.$this->IDField.'` = '.$this->Conn->qstr($session->GetID()) ); } @@ -731,9 +732,9 @@ return $this->StoreVar($name, $this->Storage->GetFromData($this, $name)); } - function GetField($var_name) + function GetField($var_name, $default = false) { - return $this->Storage->GetField($this, $var_name); + return $this->Storage->GetField($this, $var_name, $default); } function SetField($var_name, $value) Index: trunk/admin/install/install_lib.php =================================================================== diff -u -r4524 -r4867 --- trunk/admin/install/install_lib.php (.../install_lib.php) (revision 4524) +++ trunk/admin/install/install_lib.php (.../install_lib.php) (revision 4867) @@ -1037,6 +1037,6 @@ // create correct columns in ProductsCustomData table $ml_helper =& $application->recallObject('kMultiLanguageHelper'); - $ml_helper->createFields($prefix.'-cdata'); + $ml_helper->createFields($prefix.'-cdata', true); } ?> Index: trunk/core/kernel/utility/unit_config_reader.php =================================================================== diff -u -r4864 -r4867 --- trunk/core/kernel/utility/unit_config_reader.php (.../unit_config_reader.php) (revision 4864) +++ trunk/core/kernel/utility/unit_config_reader.php (.../unit_config_reader.php) (revision 4867) @@ -134,10 +134,9 @@ $this->includeConfigFiles($folderPath, $cache); $this->ParseConfigs(); - - $this->CacheParsedData(); - + if ($cache) { + $this->CacheParsedData(); $conn =& $this->Application->GetADODBConnection(); $conn->Query('REPLACE '.TABLE_PREFIX.'Cache (VarName, Data, Cached) VALUES ("config_files", '.$conn->qstr(serialize($this->configFiles)).', '.adodb_mktime().')'); } @@ -410,7 +409,7 @@ function PreloadConfigFile($filename) { - $config_found = file_exists(FULL_PATH.$filename) && ($this->configAllowed($filename) || defined('IS_INSTALL')); + $config_found = file_exists(FULL_PATH.$filename) && $this->configAllowed($filename); if( defined('DEBUG_MODE') && DEBUG_MODE && constOn('DBG_PROFILE_INCLUDES') ) { @@ -426,7 +425,7 @@ } else { - if($config_found) include_once(FULL_PATH.$filename); + if ($config_found) include_once(FULL_PATH.$filename); } if ($config_found) { @@ -582,6 +581,11 @@ */ function configAllowed($config_path) { + if (defined('IS_INSTALL') && IS_INSTALL) { + // at installation start no modules in db and kernel configs could not be read + return true; + } + $module_found = false; if (!$this->Application->ModuleInfo) return false;