summaryrefslogtreecommitdiffstats
path: root/frontends/php/popup.php
diff options
context:
space:
mode:
authorosmiy <osmiy@97f52cf1-0a1b-0410-bd0e-c28be96e8082>2007-04-04 11:33:08 +0000
committerosmiy <osmiy@97f52cf1-0a1b-0410-bd0e-c28be96e8082>2007-04-04 11:33:08 +0000
commitf4071accf03abf288b80530284abea72cbda92c3 (patch)
tree8e3f08dc56a0e4c70e9d1f1299b251981ec23e0c /frontends/php/popup.php
parente155c74da360c3024cf27f9147ff93d2bcd10ec5 (diff)
downloadzabbix-f4071accf03abf288b80530284abea72cbda92c3.tar.gz
zabbix-f4071accf03abf288b80530284abea72cbda92c3.tar.xz
zabbix-f4071accf03abf288b80530284abea72cbda92c3.zip
- added frontend-side support of external checks. (Eugene)
git-svn-id: svn://svn.zabbix.com/trunk@3974 97f52cf1-0a1b-0410-bd0e-c28be96e8082
Diffstat (limited to 'frontends/php/popup.php')
-rw-r--r--frontends/php/popup.php13
1 files changed, 6 insertions, 7 deletions
diff --git a/frontends/php/popup.php b/frontends/php/popup.php
index 8b45fd44..12bf7577 100644
--- a/frontends/php/popup.php
+++ b/frontends/php/popup.php
@@ -117,9 +117,10 @@ include_once "include/page_header.php";
"select"=> array(T_ZBX_STR, O_OPT, P_SYS|P_ACT, null, null)
);
-
- if(isset($_REQUEST['itemtype']) && !in_array($_REQUEST['itemtype'],
- array(ITEM_TYPE_ZABBIX,ITEM_TYPE_SIMPLE,ITEM_TYPE_INTERNAL,ITEM_TYPE_AGGREGATE)))
+
+ $allowed_item_types = array(ITEM_TYPE_ZABBIX,ITEM_TYPE_SIMPLE,ITEM_TYPE_INTERNAL,ITEM_TYPE_AGGREGATE);
+
+ if(isset($_REQUEST['itemtype']) && !in_array($_REQUEST['itemtype'], $allowed_item_types))
unset($_REQUEST['itemtype']);
check_fields($fields);
@@ -238,10 +239,8 @@ include_once "include/page_header.php";
{
$itemtype = get_request("itemtype",get_profile("web.popup.itemtype",0));
$cmbTypes = new CComboBox("itemtype",$itemtype,"submit()");
- $cmbTypes->AddItem(ITEM_TYPE_ZABBIX,S_ZABBIX_AGENT);
- $cmbTypes->AddItem(ITEM_TYPE_SIMPLE,S_SIMPLE_CHECK);
- $cmbTypes->AddItem(ITEM_TYPE_INTERNAL,S_ZABBIX_INTERNAL);
- $cmbTypes->AddItem(ITEM_TYPE_AGGREGATE,S_ZABBIX_AGGREGATE);
+ foreach($allowed_item_types as $type)
+ $cmbTypes->AddItem($type, item_type2str($type));
$frmTitle->AddItem(array(S_TYPE,SPACE,$cmbTypes));
}
if(in_array($srctbl,array("triggers","logitems","items",'applications')))