summaryrefslogtreecommitdiffstats
path: root/frontends/php/include/classes/graph.inc.php
diff options
context:
space:
mode:
authorosmiy <osmiy@97f52cf1-0a1b-0410-bd0e-c28be96e8082>2007-05-15 10:06:22 +0000
committerosmiy <osmiy@97f52cf1-0a1b-0410-bd0e-c28be96e8082>2007-05-15 10:06:22 +0000
commit2bd2a0b597912994b44aaaba0d097549cbefd49c (patch)
treec557188a0ccff743418ed973b81becfa018770f6 /frontends/php/include/classes/graph.inc.php
parent4894534baa0876a46909fb4429093a2289a4d9ef (diff)
downloadzabbix-2bd2a0b597912994b44aaaba0d097549cbefd49c.tar.gz
zabbix-2bd2a0b597912994b44aaaba0d097549cbefd49c.tar.xz
zabbix-2bd2a0b597912994b44aaaba0d097549cbefd49c.zip
- finished WEB monitoring (Eugene)
- tested WEB monitoring (Eugene) git-svn-id: svn://svn.zabbix.com/trunk@4137 97f52cf1-0a1b-0410-bd0e-c28be96e8082
Diffstat (limited to 'frontends/php/include/classes/graph.inc.php')
-rw-r--r--frontends/php/include/classes/graph.inc.php8
1 files changed, 5 insertions, 3 deletions
diff --git a/frontends/php/include/classes/graph.inc.php b/frontends/php/include/classes/graph.inc.php
index 845be289..14d255fa 100644
--- a/frontends/php/include/classes/graph.inc.php
+++ b/frontends/php/include/classes/graph.inc.php
@@ -239,7 +239,7 @@
function ShowTriggers($value)
{
- $this->m_showTriggers = $value == 1 ? 1 : 0;;
+ $this->m_showTriggers = $value == 1 ? 1 : 0;
}
function AddItem($itemid, $axis=GRAPH_YAXIS_SIDE_RIGHT, $calc_fnc=CALC_FNC_AVG,
@@ -306,6 +306,7 @@
{
// Avoid sizeX==0, to prevent division by zero later
if($value <= 0) $value = NULL;
+ if($value > 1300) $value = 1300;
if(is_null($value)) $value = 900;
$this->sizeX = $value;
@@ -1218,7 +1219,7 @@
$this->fullSizeX = $this->sizeX+$this->shiftXleft+$this->shiftXright+1;
$this->fullSizeY = $this->sizeY+$this->shiftY+62+12*($this->num+ (($this->sizeY < 120) ? 0 : count($this->triggers)))+8;
-
+
if(function_exists("ImageColorExactAlpha")&&function_exists("ImageCreateTrueColor")&&@imagecreatetruecolor(1,1))
$this->im = ImageCreateTrueColor($this->fullSizeX,$this->fullSizeY);
else
@@ -1324,8 +1325,9 @@
$str=sprintf("%0.2f",($end_time-$start_time));
ImageString($this->im, 0,$this->fullSizeX-120,$this->fullSizeY-12,"Generated in $str sec", $this->GetColor("Gray"));
+ unset($this->items, $this->data);
+
ImageOut($this->im);
- ImageDestroy($this->im);
}
}
?>