From 3d46f8cd88e6ae75d3c2f5ad151b031d0a275dec Mon Sep 17 00:00:00 2001 From: hugetoad Date: Sat, 26 Feb 2005 13:17:12 +0000 Subject: - support for no labels and no status in network maps (Alexei) git-svn-id: svn://svn.zabbix.com/trunk@1676 97f52cf1-0a1b-0410-bd0e-c28be96e8082 --- frontends/php/map.php | 14 +++++--------- 1 file changed, 5 insertions(+), 9 deletions(-) (limited to 'frontends/php/map.php') diff --git a/frontends/php/map.php b/frontends/php/map.php index 669df00e..6e102f41 100644 --- a/frontends/php/map.php +++ b/frontends/php/map.php @@ -326,10 +326,7 @@ else $color=$darkyellow; -// if( strstr($label,"%s")) -// { $label=expand_trigger_description_simple(DBget_field($result1,0,1)); -// } } else if($count>1) { @@ -348,12 +345,11 @@ { $y1=$y1+ImageFontHeight(2); } - ImageFilledRectangle($im,$x1-2, $y1,$x1+ImageFontWidth(2)*strlen($label), $y1+ImageFontHeight(2),$white); - ImageString($im, 2, $x1, $y1, $label,$color); - -# ImageFilledRectangle($im,$x+ImageSX($img)/2-ImageFontWidth(2)*strlen($label)/2-2, $y+ImageSY($img),$x+ImageSX($img)/2+ImageFontWidth(2)*strlen($label)/2, $y+ImageSY($img)+ImageFontHeight(2),$white); -# ImageString($im, 2, $x+ImageSX($img)/2-ImageFontWidth(2)*strlen($label)/2, $y+ImageSY($img)+ImageFontHeight(2), $label,$color); -# ImageDestroy($img); + if($label_type!=MAP_LABEL_TYPE_NOTHING) + { + ImageFilledRectangle($im,$x1-2, $y1,$x1+ImageFontWidth(2)*strlen($label), $y1+ImageFontHeight(2),$white); + ImageString($im, 2, $x1, $y1, $label,$color); + } } ImageStringUp($im,0,imagesx($im)-10,imagesy($im)-50, S_ZABBIX_URL, $gray); -- cgit