ftimme
2013-07-02 d8d24cf1d70351e6c9a8180829273cbd8ebc5e87
- Fixed FS#2965 - DNS SOA edit form: xfer validation generates also_notify error message.
2 files modified
4 ■■■■ changed files
interface/lib/classes/tform.inc.php 1 ●●●● patch | view | raw | blame | history
interface/web/dns/dns_soa_edit.php 3 ●●●●● patch | view | raw | blame | history
interface/lib/classes/tform.inc.php
@@ -951,6 +951,7 @@
                                        $field_value_array[] = $field_value;
                                    }
                                    foreach($field_value_array as $field_value) {
                                        $field_value = trim($field_value);
                                        if(function_exists('filter_var')) {
                                            if(!filter_var($field_value,FILTER_VALIDATE_IP)) {
                                                $errmsg = $validator['errmsg'];
interface/web/dns/dns_soa_edit.php
@@ -172,6 +172,9 @@
        if(stristr($this->dataRecord["mbox"],'@')) {
            $this->dataRecord["mbox"] = str_replace('@','.',$this->dataRecord["mbox"]);
        }
        $this->dataRecord["xfer"] = preg_replace('/\s+/', '', $this->dataRecord["xfer"]);
        $this->dataRecord["also_notify"] = preg_replace('/\s+/', '', $this->dataRecord["also_notify"]);
        //* Check if a secondary zone with the same name already exists     
        $tmp = $app->db->queryOneRecord("SELECT count(id) as number FROM dns_slave WHERE origin = \"".$this->dataRecord["origin"]."\" AND server_id = \"".$this->dataRecord["server_id"]."\"");