Code

Schema check is now configurable vai gosa.conf
authorhickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8>
Wed, 18 Jan 2006 12:20:53 +0000 (12:20 +0000)
committerhickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8>
Wed, 18 Jan 2006 12:20:53 +0000 (12:20 +0000)
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@2524 594d385d-05f5-0310-b6e9-bd551577e9d8

html/index.php

index fcfe3445bbe75a9809a6779621bc9b9dd07d3af1..f11f8514a536c26e8478b966f4d97118a194fe0f 100644 (file)
@@ -140,23 +140,24 @@ if ($_SERVER["REQUEST_METHOD"] == "POST" && isset($_POST['login'])){
   }
 
   /* Check for schema file presence */
-  require_once("functions_setup.inc");
-  if(!is_schema_readable($config->current['SERVER'],$config->current['ADMIN'],$config->current['PASSWORD'])){
-    print_red(_("GOsa cannot retrieve information about the installed schema files. Please make sure, that this is possible."));
-    echo $_SESSION['errors'];
-    exit();
-  }else{
-    $str = (schema_check($config->current['SERVER'],$config->current['ADMIN'],$config->current['PASSWORD'],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."));
-        print $_SESSION['errors'];
-        exit();
+  if(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'])){
+      print_red(_("GOsa cannot retrieve information about the installed schema files. Please make sure, that this is possible."));
+      echo $_SESSION['errors'];
+      exit();
+    }else{
+      $str = (schema_check($config->current['SERVER'],$config->current['ADMIN'],$config->current['PASSWORD'],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."));
+          print $_SESSION['errors'];
+          exit();
+        }
       }
     }
   }
-
   /* Check for locking area */
   $ldap->cat($config->current['CONFIG']);
   $attrs= $ldap->fetch();