diff options
| author | osmiy <osmiy@97f52cf1-0a1b-0410-bd0e-c28be96e8082> | 2007-05-14 12:30:14 +0000 |
|---|---|---|
| committer | osmiy <osmiy@97f52cf1-0a1b-0410-bd0e-c28be96e8082> | 2007-05-14 12:30:14 +0000 |
| commit | 77ddebaf537a1c9d5a98e6ba7cbefce50b64d27f (patch) | |
| tree | 7bb757f88228440455f58990b3cc71c2d3e123cc /frontends/php/include/httptest.inc.php | |
| parent | 90f1044ad520c79987196bdeb408877bc571bbd4 (diff) | |
| download | zabbix-77ddebaf537a1c9d5a98e6ba7cbefce50b64d27f.tar.gz zabbix-77ddebaf537a1c9d5a98e6ba7cbefce50b64d27f.tar.xz zabbix-77ddebaf537a1c9d5a98e6ba7cbefce50b64d27f.zip | |
- added http status code configuration for web monitoring (Eugene)
git-svn-id: svn://svn.zabbix.com/trunk@4130 97f52cf1-0a1b-0410-bd0e-c28be96e8082
Diffstat (limited to 'frontends/php/include/httptest.inc.php')
| -rw-r--r-- | frontends/php/include/httptest.inc.php | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/frontends/php/include/httptest.inc.php b/frontends/php/include/httptest.inc.php index 1a394336..409d992a 100644 --- a/frontends/php/include/httptest.inc.php +++ b/frontends/php/include/httptest.inc.php @@ -45,7 +45,7 @@ return $status; } - function db_save_step($hostid, $applicationid, $httptestid, $testname, $name, $no, $timeout, $url, $posts, $required, $delay, $history, $trends) + function db_save_step($hostid, $applicationid, $httptestid, $testname, $name, $no, $timeout, $url, $posts, $required, $status_codes, $delay, $history, $trends) { if (!eregi('^([0-9a-zA-Z\_\.[.-.]\$ ]+)$', $name)) { @@ -59,10 +59,10 @@ $httpstepid = get_dbid("httpstep","httpstepid"); if (!DBexecute('insert into httpstep'. - ' (httpstepid, httptestid, name, no, url, timeout, posts, required) '. + ' (httpstepid, httptestid, name, no, url, timeout, posts, required, status_codes) '. ' values ('.$httpstepid.','.$httptestid.','.zbx_dbstr($name).','.$no.','. zbx_dbstr($url).','.$timeout.','. - zbx_dbstr($posts).','.zbx_dbstr($required).')' + zbx_dbstr($posts).','.zbx_dbstr($required).','.zbx_dbstr($status_codes).')' )) return false; } else @@ -71,7 +71,7 @@ if (!DBexecute('update httpstep set '. ' name='.zbx_dbstr($name).', no='.$no.', url='.zbx_dbstr($url).', timeout='.$timeout.','. - ' posts='.zbx_dbstr($posts).', required='.zbx_dbstr($required). + ' posts='.zbx_dbstr($posts).', required='.zbx_dbstr($required).', status_codes='.zbx_dbstr($status_codes). ' where httpstepid='.$httpstepid)) return false; } @@ -207,10 +207,11 @@ if(!isset($s['timeout'])) $s['timeout'] = 15; if(!isset($s['url'])) $s['url'] = ''; if(!isset($s['posts'])) $s['posts'] = ''; - if(!isset($s['required'])) $s['required'] = ''; + if(!isset($s['required'])) $s['required'] = ''; + if(!isset($s['status_codes'])) $s['status_codes'] = ''; $result = db_save_step($hostid, $applicationid, $httptestid, - $name, $s['name'], $sid, $s['timeout'], $s['url'], $s['posts'], $s['required'], + $name, $s['name'], $sid, $s['timeout'], $s['url'], $s['posts'], $s['required'],$s['status_codes'], $delay, $history, $trends); if(!$result) break; |
