From c1fcaed2ee8f05a5030fe4e8e211ca4eae7a9489 Mon Sep 17 00:00:00 2001
From: ftimme <ft@falkotimme.com>
Date: Tue, 11 Jun 2013 11:44:57 -0400
Subject: [PATCH] - Fixed FS#2921 - RBL list field in server config can not be empty.
---
interface/web/dns/form/dns_rp.tform.php | 34 ++++++++++++++++++++++++++++------
1 files changed, 28 insertions(+), 6 deletions(-)
diff --git a/interface/web/dns/form/dns_rp.tform.php b/interface/web/dns/form/dns_rp.tform.php
index 9d80a35..f6a6ef5 100644
--- a/interface/web/dns/form/dns_rp.tform.php
+++ b/interface/web/dns/form/dns_rp.tform.php
@@ -32,6 +32,7 @@
*/
+global $app;
$form["title"] = "DNS RP";
$form["description"] = "";
@@ -69,18 +70,23 @@
'zone' => array (
'datatype' => 'INTEGER',
'formtype' => 'TEXT',
- 'default' => intval($_REQUEST["zone"]),
+ 'default' => @$app->functions->intval($_REQUEST["zone"]),
'value' => '',
'width' => '30',
'maxlength' => '255'
),
+ 'filters' => array( 0 => array( 'event' => 'SAVE',
+ 'type' => 'IDNTOASCII'),
+ 1 => array( 'event' => 'SHOW',
+ 'type' => 'IDNTOUTF8'),
+ 2 => array( 'event' => 'SAVE',
+ 'type' => 'TOLOWER')
+ ),
'name' => array (
'datatype' => 'VARCHAR',
'formtype' => 'TEXT',
- 'validators' => array ( 0 => array ( 'type' => 'NOTEMPTY',
- 'errmsg'=> 'name_error_empty'),
- 1 => array ( 'type' => 'REGEX',
- 'regex' => '/^[\w\.\-]{1,64}$/',
+ 'validators' => array ( 0 => array ( 'type' => 'REGEX',
+ 'regex' => '/^[\w\.\-]{0,255}$/',
'errmsg'=> 'name_error_regex'),
),
'default' => '',
@@ -102,7 +108,7 @@
'validators' => array ( 0 => array ( 'type' => 'NOTEMPTY',
'errmsg'=> 'data_error_empty'),
1 => array ( 'type' => 'REGEX',
- 'regex' => '/^[0-9\.]{10,15}$/',
+ 'regex' => '/^[\w\.\-\s]{1,128}$/',
'errmsg'=> 'data_error_regex'),
),
'default' => '',
@@ -134,6 +140,22 @@
'default' => 'Y',
'value' => array(0 => 'N',1 => 'Y')
),
+ 'stamp' => array (
+ 'datatype' => 'VARCHAR',
+ 'formtype' => 'TEXT',
+ 'default' => '',
+ 'value' => '',
+ 'width' => '30',
+ 'maxlength' => '255'
+ ),
+ 'serial' => array (
+ 'datatype' => 'INTEGER',
+ 'formtype' => 'TEXT',
+ 'default' => '',
+ 'value' => '',
+ 'width' => '10',
+ 'maxlength' => '10'
+ ),
##################################
# ENDE Datatable fields
##################################
--
Gitblit v1.9.1