diff --git a/html/index.php b/html/index.php
index 9877161c96ac60495c7d8eba693a47098718cca0..1fdcf4bb3b91d101f6385ad10e4d0de6828ffd21 100644 (file)
--- a/html/index.php
+++ b/html/index.php
$_SESSION['LastError'] = "";
/* Check if we need to run setup */
-if (!file_exists(CONFIG_DIR."/gosa.conf")){
+if (!file_exists(CONFIG_DIR."/gosa.conf-trunk")){
header("location:setup.php");
exit();
}
}
if(isset($config->data['MAIN']['SCHEMA_CHECK'])&&preg_match("/true/i",$config->data['MAIN']['SCHEMA_CHECK'])){
require_once("functions_setup.inc");
- if(!is_schema_readable($config->current['SERVER'],$config->current['ADMIN'],$config->current['PASSWORD'])){
+ $recursive = (isset($config->current['RECURSIVE']) && $config->current['RECURSIVE'] == "true");
+ $tls = (isset($config->current['TLS']) && $config->current['TLS'] == "true");
+
+ if(!is_schema_readable($config->current['SERVER'], $config->current['ADMIN'], $config->current['PASSWORD'], $recursive, $tls)){
+
print_red(_("GOsa cannot retrieve information about the installed schema files. Please make sure, that this is possible."));
- $smarty->display(get_template_path('headers.tpl'));
- echo "<body>".$_SESSION['errors']."</body></html>";
- exit();
+ displayLogin();
+ exit() ;
}else{
- $str = (schema_check($config->current['SERVER'],$config->current['ADMIN'],$config->current['PASSWORD'],0,TRUE));
+ $str = (schema_check($config->current['SERVER'],$config->current['ADMIN'],$config->current['PASSWORD'], $recursive, $tls, 0, TRUE));
$checkarr = array();
foreach($str as $tr){
if(isset($tr['needonstartup'])){
print_red($tr['msg']."<br>"._("Your ldap setup contains old schema definitions. Please re-run the setup."));
- $smarty->display(get_template_path('headers.tpl'));
- echo "<body>".$_SESSION['errors']."</body></html>";
- exit();
+ displayLogin();
+ exit() ;
}
}
}