diff options
| author | artem <artem@97f52cf1-0a1b-0410-bd0e-c28be96e8082> | 2008-02-22 15:28:41 +0000 |
|---|---|---|
| committer | artem <artem@97f52cf1-0a1b-0410-bd0e-c28be96e8082> | 2008-02-22 15:28:41 +0000 |
| commit | 9848b90bd9eddf0324ffdc0d8f089c6c24683fe8 (patch) | |
| tree | 755bae71a9ecbc5d3f3c9085c0583a345c0c00d8 /frontends/php/include/html.inc.php | |
| parent | 2a35ecbf642a185e3b53f66f783272e03fe99e93 (diff) | |
| download | zabbix-9848b90bd9eddf0324ffdc0d8f089c6c24683fe8.tar.gz zabbix-9848b90bd9eddf0324ffdc0d8f089c6c24683fe8.tar.xz zabbix-9848b90bd9eddf0324ffdc0d8f089c6c24683fe8.zip | |
- [DEV-118] added dashboard screen to monitoring (Artem)
- [ZBX-206] merged rev.5367:5370 of 1.4/ (Artem) [fixed case sensitive hosts sorting]
- [DEV-119] changes how users online are counted (Artem)
- implemented patch [added y axis calculation type: "Calculated [Min=0]"] (Artem)
- changes in schema.sql (Artem)
- fixed JS lib, url class (Artem)
- some other small fixes (Artem)
git-svn-id: svn://svn.zabbix.com/trunk@5387 97f52cf1-0a1b-0410-bd0e-c28be96e8082
Diffstat (limited to 'frontends/php/include/html.inc.php')
| -rw-r--r-- | frontends/php/include/html.inc.php | 42 |
1 files changed, 41 insertions, 1 deletions
diff --git a/frontends/php/include/html.inc.php b/frontends/php/include/html.inc.php index 719ce7de..6946ecd4 100644 --- a/frontends/php/include/html.inc.php +++ b/frontends/php/include/html.inc.php @@ -106,4 +106,44 @@ function BR(){ return new CTag('br','no'); } -?> + + function create_hat($caption,$items,$addicons=null,$id=null,$state=1){ + + if(is_null($id)){ + list($usec, $sec) = explode(' ',microtime()); + $id = 'hat_'.((int)($sec % 10)).((int)($usec * 1000)); + } + + $td_l = new CCol(SPACE); + $td_l->AddOption('width','100%'); + + $icons_row = array($td_l); + if(!is_null($addicons)){ + if(!is_array($addicons)) $addicons = array($addicons); + foreach($addicons as $value) $icons_row[] = $value; + } + + $icon = new CDiv(SPACE,($state)?'arrowup':'arrowdown'); + $icon->AddAction('onclick',new CScript("javascript: change_hat_state(this,'".$id."');")); + + $icons_row[] = $icon; + + $icon_tab = new CTable(); + $icon_tab->AddOption('width','100%'); + + $icon_tab->AddRow($icons_row); + + $table = new CTable(); + $table->AddOption('width','100%'); + $table->SetCellPadding(0); + $table->SetCellSpacing(0); + $table->AddRow(get_table_header($caption,$icon_tab)); + + $div = new CDiv($items); + $div->AddOption('id',$id); + if(!$state) $div->AddOption('style','display: none;'); + + $table->AddRow($div); + return $table; + } +?>
\ No newline at end of file |
