diff options
| author | osmiy <osmiy@97f52cf1-0a1b-0410-bd0e-c28be96e8082> | 2006-02-23 09:19:39 +0000 |
|---|---|---|
| committer | osmiy <osmiy@97f52cf1-0a1b-0410-bd0e-c28be96e8082> | 2006-02-23 09:19:39 +0000 |
| commit | 80f4db7614471e99bbcf303e2702bbe44b0a72c2 (patch) | |
| tree | 6873e04ad27ad82545bf7bf9ee1ac0b2ec490eb1 /frontends/php/chart2.php | |
| parent | cfdccc6dd4f9d313f6cdc34f62f6453a1f5a1a0b (diff) | |
| download | zabbix-80f4db7614471e99bbcf303e2702bbe44b0a72c2.tar.gz zabbix-80f4db7614471e99bbcf303e2702bbe44b0a72c2.tar.xz zabbix-80f4db7614471e99bbcf303e2702bbe44b0a72c2.zip | |
- added Hostname for graphs displaying (Eugene)
git-svn-id: svn://svn.zabbix.com/trunk@2676 97f52cf1-0a1b-0410-bd0e-c28be96e8082
Diffstat (limited to 'frontends/php/chart2.php')
| -rw-r--r-- | frontends/php/chart2.php | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/frontends/php/chart2.php b/frontends/php/chart2.php index 6df46a4f..34d7e47c 100644 --- a/frontends/php/chart2.php +++ b/frontends/php/chart2.php @@ -42,8 +42,14 @@ $result=DBselect("select name,width,height,yaxistype,yaxismin,yaxismax from graphs where graphid=".$_REQUEST["graphid"]); $row=DBfetch($result); - + $db_hosts = get_hosts_by_graphid($_REQUEST["graphid"]); $name=$row["name"]; + + if(DBnum_rows($db_hosts)==1) + { + $db_host = DBfetch($db_hosts); + $name = $db_host["host"].":".$name; + } if(isset($_REQUEST["width"])&&$_REQUEST["width"]>0) { $width=$_REQUEST["width"]; @@ -63,7 +69,7 @@ $graph->setWidth($width); $graph->setHeight($height); - $graph->setHeader($row["name"]); + $graph->setHeader($name); $graph->setYAxisType($row["yaxistype"]); $graph->setYAxisMin($row["yaxismin"]); $graph->setYAxisMax($row["yaxismax"]); |
