diff options
| author | artem <artem@97f52cf1-0a1b-0410-bd0e-c28be96e8082> | 2007-10-08 11:59:15 +0000 |
|---|---|---|
| committer | artem <artem@97f52cf1-0a1b-0410-bd0e-c28be96e8082> | 2007-10-08 11:59:15 +0000 |
| commit | f99327ef29f466bac40fdd47413d1a9cab9b3690 (patch) | |
| tree | 48748ced776efb2490b7c382dcfb7c002ffb2130 /frontends/php/hosts.php | |
| parent | 09174fc6e94e7ff57d3d1e9f8dd134be4d7645c7 (diff) | |
| download | zabbix-f99327ef29f466bac40fdd47413d1a9cab9b3690.tar.gz zabbix-f99327ef29f466bac40fdd47413d1a9cab9b3690.tar.xz zabbix-f99327ef29f466bac40fdd47413d1a9cab9b3690.zip | |
- [DEV-50] merged rev. 4841:4843 of branches/1.4/ (Artem) [improved incoming parameters exception validation]
git-svn-id: svn://svn.zabbix.com/trunk@4847 97f52cf1-0a1b-0410-bd0e-c28be96e8082
Diffstat (limited to 'frontends/php/hosts.php')
| -rw-r--r-- | frontends/php/hosts.php | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/frontends/php/hosts.php b/frontends/php/hosts.php index 3256f737..18237a0f 100644 --- a/frontends/php/hosts.php +++ b/frontends/php/hosts.php @@ -65,13 +65,13 @@ include_once "include/page_header.php"; "groups"=> array(T_ZBX_INT, O_OPT, P_SYS, DB_ID, NULL), "applications"=>array(T_ZBX_INT, O_OPT, P_SYS, DB_ID, NULL), /* host */ - "hostid"=> array(T_ZBX_INT, O_OPT, P_SYS, DB_ID, '{config}==0&&{form}=="update"'), - "host"=> array(T_ZBX_STR, O_OPT, NULL, NOT_EMPTY, '({config}==0||{config}==3)&&isset({save})'), - "dns"=> array(T_ZBX_STR, O_OPT, NULL, NULL, '{config}==0&&isset({save})'), - "useip"=> array(T_ZBX_STR, O_OPT, NULL, IN('0,1'), '{config}==0&&isset({save})'), - "ip"=> array(T_ZBX_IP, O_OPT, NULL, NULL, '{config}==0&&isset({save})'), - "port"=> array(T_ZBX_INT, O_OPT, NULL, BETWEEN(0,65535),'{config}==0&&isset({save})'), - "status"=> array(T_ZBX_INT, O_OPT, NULL, IN("0,1,3"), '{config}==0&&isset({save})'), + "hostid"=> array(T_ZBX_INT, O_OPT, P_SYS, DB_ID, '(isset({config})&&({config}==0))&&(isset({form})&&({form}=="update"))'), + "host"=> array(T_ZBX_STR, O_OPT, NULL, NOT_EMPTY, 'isset({config})&&({config}==0||{config}==3)&&isset({save})'), + "dns"=> array(T_ZBX_STR, O_OPT, NULL, NULL, '(isset({config})&&({config}==0))&&isset({save})'), + "useip"=> array(T_ZBX_STR, O_OPT, NULL, IN('0,1'), '(isset({config})&&({config}==0))&&isset({save})'), + "ip"=> array(T_ZBX_IP, O_OPT, NULL, NULL, '(isset({config})&&({config}==0))&&isset({save})'), + "port"=> array(T_ZBX_INT, O_OPT, NULL, BETWEEN(0,65535),'(isset({config})&&({config}==0))&&isset({save})'), + "status"=> array(T_ZBX_INT, O_OPT, NULL, IN("0,1,3"), '(isset({config})&&({config}==0))&&isset({save})'), "newgroup"=> array(T_ZBX_STR, O_OPT, NULL, NULL, NULL), "templates"=> array(T_ZBX_STR, O_OPT, NULL, NOT_EMPTY, NULL), @@ -90,13 +90,13 @@ include_once "include/page_header.php"; "location"=> array(T_ZBX_STR, O_OPT, NULL, NULL, 'isset({useprofile})'), "notes"=> array(T_ZBX_STR, O_OPT, NULL, NULL, 'isset({useprofile})'), /* group */ - "groupid"=> array(T_ZBX_INT, O_OPT, P_SYS, DB_ID, '{config}==1&&{form}=="update"'), - "gname"=> array(T_ZBX_STR, O_OPT, NULL, NOT_EMPTY, '{config}==1&&isset({save})'), + "groupid"=> array(T_ZBX_INT, O_OPT, P_SYS, DB_ID, '(isset({config})&&({config}==1))&&(isset({form})&&({form}=="update"))'), + "gname"=> array(T_ZBX_STR, O_OPT, NULL, NOT_EMPTY, '(isset({config})&&({config}==1))&&isset({save})'), /* application */ - "applicationid"=>array(T_ZBX_INT,O_OPT, P_SYS, DB_ID, '{config}==4&&{form}=="update"'), - "appname"=> array(T_ZBX_STR, O_NO, NULL, NOT_EMPTY, '{config}==4&&isset({save})'), - "apphostid"=> array(T_ZBX_INT, O_OPT, NULL, DB_ID.'{}>0', '{config}==4&&isset({save})'), + "applicationid"=>array(T_ZBX_INT,O_OPT, P_SYS, DB_ID, '(isset({config})&&({config}==4))&&(isset({form})&&({form}=="update"))'), + "appname"=> array(T_ZBX_STR, O_NO, NULL, NOT_EMPTY, '(isset({config})&&({config}==4))&&isset({save})'), + "apphostid"=> array(T_ZBX_INT, O_OPT, NULL, DB_ID.'{}>0', '(isset({config})&&({config}==4))&&isset({save})'), "apptemplateid"=>array(T_ZBX_INT,O_OPT, NULL, DB_ID, NULL), /* actions */ |
