Skip to content
Snippets Groups Projects
Commit a969f107 authored by Hahn Axel (hahn)'s avatar Hahn Axel (hahn)
Browse files

update menu item for user profile

parent 9448ea24
No related branches found
No related tags found
1 merge request!62V2.0
......@@ -14,67 +14,6 @@ global $aParams;
$aParams = array();
// ----------------------------------------------------------------------
// verifiy config
// ----------------------------------------------------------------------
/*
$aErrors=array();
if (!isset($aConfig) || !is_array($aConfig)) {
$aErrors[]="* \$aConfig does not exist. The config was not included before including " . __FILE__ . " in the request/ script.\n";
} else {
foreach (array(
'appRootDir',
'configDir',
'workDir',
'dataDir',
'buildDir',
'buildDefaultsDir',
'packageDir',
'archiveDir',
) as $sKey){
if (!is_dir($aConfig[$sKey])){
$aErrors[]="* \$aConfig['$sKey'] points to a non existing directory (".$aConfig[$sKey].").\n";
} else {
if (!is_writable($aConfig[$sKey])){
$aErrors[]="* \$aConfig['$sKey'] = ".$aConfig[$sKey]." is NOT writable.\n";
}
}
}
}
foreach (array(
$aConfig['dataDir'].'/database',
$aConfig['dataDir'].'/projects',
$aConfig['dataDir'].'/sshkeys',
) as $sDir2Check){
if (!is_dir($sDir2Check)){
$aErrors[]="* directory not found: $sDir2Check\n";
} else {
if (!is_writable($sDir2Check)){
$aErrors[]="* $sDir2Check is NOT writable.\n";
}
}
}
// check required keys in the config
foreach (array(
'auth',
'hooks',
'installPackages',
'lang',
'phases',
'projects',
) as $sKey){
if (!array_key_exists($sKey, $aConfig)){
$aErrors[]="* missing key directory [$sKey] in config\n";
}
}
if (count($aErrors)){
die("FATAL ERROR on config.<br>" . implode("<br>\n", $aErrors));
}
*/
// remark: $_SERVER does not exist in CLI
if (isset($_SERVER) && is_array($_SERVER) && array_key_exists("REQUEST_URI", $_SERVER)) {
/*
......@@ -300,7 +239,7 @@ function getTopNavRight() {
['href'=>'#', 'label'=>$oUser->getUsername(), 'icon'=>'fa-solid fa-user',
'class'=>($sCurrentAction=='login' ? 'active' :''),
'children'=>[
['href'=>$sBaseUrl . 'all/login/', 'label'=>t("login"), 'icon'=>'fa-solid fa-right-to-bracket', 'class'=>($sCurrentAction=='login' ? 'active' :'') ],
['href'=>$sBaseUrl . 'all/login/', 'label'=>t("userprofile"), 'icon'=>'fa-regular fa-id-card', 'class'=>($sCurrentAction=='login' ? 'active' :'') ],
]
]
];
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment