Add option to disable LDAP configuration.
authorJan Schneider <jan@horde.org>
Mon, 5 Jul 2010 22:16:49 +0000 (00:16 +0200)
committerJan Schneider <jan@horde.org>
Mon, 5 Jul 2010 22:31:27 +0000 (00:31 +0200)
framework/Core/lib/Horde/Config.php

index ecd3a1c..b2df8a0 100644 (file)
@@ -731,7 +731,20 @@ class Horde_Config
         );
 
         if (isset($node) && $node->getAttribute('baseconfig') == 'true') {
-            return $fields;
+            return array(
+                'desc' => 'Use LDAP?',
+                'default' => $this->_default($ctx . '|' . $node->getAttribute('switchname'), false),
+                'switch' => array(
+                    'false' => array(
+                        'desc' => 'No',
+                        'fields' => array()
+                    ),
+                    'true' => array(
+                        'desc' => 'Yes',
+                        'fields' => $fields
+                    ),
+                )
+            );
         }
 
         list($default, $isDefault) = $this->__default($ctx . '|' . (isset($node) ? $node->getAttribute('switchname') : $switchname), 'horde');