Code

Removed debug output
authorhickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8>
Wed, 18 May 2011 12:07:26 +0000 (12:07 +0000)
committerhickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8>
Wed, 18 May 2011 12:07:26 +0000 (12:07 +0000)
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@20858 594d385d-05f5-0310-b6e9-bd551577e9d8

gosa-plugins/goto-ng/admin/newConfigManagement/TemplateEngine/class_TemplateWidget.inc
gosa-plugins/goto-ng/admin/newConfigManagement/class_newConfigManagement.inc

index bc66f8f0a929ae6a1315734b931418d0e14a9a17..b5e48a5a6c1b6e99c97e0c54b018496ac1f5e488 100644 (file)
@@ -130,8 +130,10 @@ class TemplateWidget
         if($this->required && empty($this->value)){
             return(array(msgPool::required($this->display)));
         }
-        if(!empty($this->value) && !empty($this->syntax) && !preg_match("/".$this->syntax."/", $this->value)){
-            return(array(msgPool::invalid($this->display, $this->value, "/".$this->syntax."/")));
+        if(!empty($this->value) && 
+            !empty($this->syntax) &&
+            !empty($this->syntax) && !preg_match($this->syntax, $this->value)){
+            return(array(msgPool::invalid($this->display, $this->value, $this->syntax)));
         }
         return(array());
     }
index a04056ce1b2dba3a5aa88c2f2dca96001f566e7b..4168b36434133fed389f7c0f9ff8463b16850429 100644 (file)
@@ -727,8 +727,8 @@ class newConfigManagement extends plugin
             }
             if(in_array($values['name'],$usedNames)){
                 $msgs[] = msgPool::duplicated(_("Name"));
-            }elseif(preg_match("/[^a-z0-9\.]/i",$values['name'])){
-                $msgs[] = msgPool::invalid(_("Name"), $values['name'], '/[a-z0-9\.]/');
+            #}elseif(preg_match("/[^a-z0-9\.]/i",$values['name'])){
+            #    $msgs[] = msgPool::invalid(_("Name"), $values['name'], '/[a-z0-9\.]/');
             }
         }