From: hickert Date: Wed, 8 Feb 2006 07:18:13 +0000 (+0000) Subject: Added lowercase check for all record types X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=b6531026ea7bc102ac7a487bf6d534f3080fbe23;p=gosa.git Added lowercase check for all record types git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@2638 594d385d-05f5-0310-b6e9-bd551577e9d8 --- diff --git a/plugins/admin/systems/class_termDNS.inc b/plugins/admin/systems/class_termDNS.inc index 1d1ea145c..2a2e7df25 100644 --- a/plugins/admin/systems/class_termDNS.inc +++ b/plugins/admin/systems/class_termDNS.inc @@ -256,10 +256,19 @@ class termDNS extends plugin $message[]=(_("The given macaddress is invalid. There must be 6 1byte segments seperated by ':'.")); } + /* only perfrom this checks if this is a valid DNS account */ if($this->DNS_is_account){ foreach($this->types as $name => $values){ + + /* Check if there is an aRecord defined which uses the same IP as used in IPhostAddress */ if(($values['type'] == "aRecord")&&($values['value'] == $this->ipHostNumber)&&($values['status']!="deleted")){ - $message[]=sprintf(_("The device IP '%s' is added as 'A Record', this will be done automatically, please remove the record."),$this->ipHostNumber); + $message[]=sprintf(_("The device IP '%s' is added as 'A Record', this will be done automatically, please remove the record."), + $this->ipHostNumber); + } + + /* only lower-case is allowed in record entries ... */ + if($values['value'] != strtolower($values['value'])){ + $message[] = sprintf(_("Only lowercase is allowed, please check your '%ss'."),$values['type']); } } } @@ -342,7 +351,8 @@ class termDNS extends plugin } - + /* Create html table with all used record types + */ function generateRecordsList($changeStateForRecords) { $changeStateForRecords = ""; @@ -376,6 +386,7 @@ class termDNS extends plugin return($str); } + /* Create a html select box which allows us to select different types of records */ function generateRecordListBox($selected,$name) { $str = "